Git Product home page Git Product logo

datatyping's People

Contributors

carlbordum avatar dgarciasarai avatar illright avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

datatyping's Issues

Implement datatyping.printer with subclassing

I was super stupid, when I implemented datatyping.printer.py. It should be implemented with subclassing instead of monkey patching (with context managers). This would also make it thread-safe.

Relevant: #2.

Tests based on real world apis

It would be cool if we included test data from some open apis. Any ideas?

I dont want the tests to fetch the data everytime. It should be hardcoded or read from a file.

AttributeError: type object 'PrettyPrinter' has no attribute '_format_dict_items'

When running with Python 3.4

web_1        | Traceback (most recent call last):
web_1        |   File "/code/project_name/apps/students/util.py", line 227, in EDEXML_reader
web_1        |     pprint(groups_output)
web_1        |   File "/usr/local/lib/python3.4/site-packages/datatyping/printer.py", line 111, in pprint
web_1        |     with change_pprint_repr():
web_1        |   File "/usr/local/lib/python3.4/contextlib.py", line 59, in __enter__
web_1        |     return next(self.gen)
web_1        |   File "/usr/local/lib/python3.4/site-packages/datatyping/printer.py", line 101, in change_pprint_repr
web_1        |     old_format_dict_items = _pprint.PrettyPrinter._format_dict_items
web_1        | AttributeError: type object 'PrettyPrinter' has no attribute '_format_dict_items'

Looking at https://github.com/python/cpython/blob/3.4/Lib/pprint.py you can see that this was introduced in 3.5: https://github.com/python/cpython/blob/3.5/Lib/pprint.py.

Might be worth mentioning that only Python 3.5 and higher are supported!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.