-
Notifications
You must be signed in to change notification settings - Fork 11
Fix python 3.6 metaclass compatibility #10
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
base: master
Are you sure you want to change the base?
Conversation
|
Also kudos to @encukou for his help with this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is not compiling, but after fixing them the unit tests pass on 3.6.
beanbag/namespace.py
Outdated
| conv_nmspc["__module__"] = nmspc["__module__"] | ||
| if qn is not None: | ||
| conv_nmspc["__qualname__"] = qn | ||
| if classcell is not None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing : after None
beanbag/namespace.py
Outdated
| qn = nmspc["__qualname__"] | ||
| nmspc["__qualname__"] = qn + "Base" | ||
|
|
||
| classcell = nmspc.pop('__classcell__', None) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initialize classcell to None before line 107
|
Thanks for taking a look at it. Made the changes you requested. |
gustavlarson
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
beanbag/namespace.py
Outdated
| conv_nmspc["__module__"] = nmspc["__module__"] | ||
| if qn is not None: | ||
| conv_nmspc["__qualname__"] = qn | ||
| if classcell is not None: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: two spaces in is not here
ktdreyer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajtowns mind merging this?
StykMartin
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any plans for merge? Or we can consider this project as completely dead.
Currently the test_sane_inheritance fail for Python 3.6
This is due to the changes done at: http://bugs.python.org/issue23722
Also some more details can be found here: https://docs.python.org/3/reference/datamodel.html#creating-the-class-object
This pull request addresses this issue for Python 3.6.