Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renamed types.py to otypes.py, to stop shadowing the python types module #132

Merged
merged 1 commit into from
Oct 28, 2015

Conversation

obi1kenobi
Copy link
Contributor

The types.py file was shadowing the python builtin types module, causing python to fail to start when in the pyorient directory:

$ python
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site.py", line 62, in <module>
    import os
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/os.py", line 400, in <module>
    import UserDict
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/UserDict.py", line 83, in <module>
    import _abcoll
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/_abcoll.py", line 70, in <module>
    Iterable.register(str)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/abc.py", line 107, in register
    if not isinstance(subclass, (type, types.ClassType)):
AttributeError: 'module' object has no attribute 'ClassType'

This renames the problematic file to otypes.py following OrientDB's convention of prefixing types with an 'o'.

mogui added a commit that referenced this pull request Oct 28, 2015
Renamed types.py to otypes.py, to stop shadowing the python types module
@mogui mogui merged commit f138072 into mogui:develop Oct 28, 2015
@mogui
Copy link
Owner

mogui commented Oct 28, 2015

yup what a bad things !
thanks for it

@obi1kenobi obi1kenobi deleted the types_rename branch October 28, 2015 19:26
@obi1kenobi
Copy link
Contributor Author

Glad I could help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants