-
Notifications
You must be signed in to change notification settings - Fork 71
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
pkg_resources.declare_namespace
is deprecated
#270
Comments
Unfortunately as https://packaging.python.org/en/latest/guides/packaging-namespace-packages/#pkg-resources-style-namespace-packages says:
It's not clear that it's possible to fix this. If a method exists that doesn't break things then I'd be very interested to hear about it! |
Hmm a way forward is definitely unclear, I've opened a setuptools issue asking about this: pypa/setuptools#3943 |
Takeaway from the above PyPA issue: Once we have one pep420 namespace package in our installation we lose the ability to do a This according to the example package here https://github.com/pypa/sample-namespace-packages |
A major breaking change for any namespace then 😱 if we coordinate enough, for zope and plone that might still work, but for collective... that's going to be a minefield 😕 |
What I found out is that it is not always possible to mix PEP 420 installations with the currently used namespaces: If I install a namespaced package using The only way I see is to migrate the whole namespace. |
BUG
What I did:
Imported zope.interface (through gevent).
What I expect to happen:
No warning.
What actually happened:
The method zope.interface uses to declare a namespace package is deprecated in latest setuptools:
The relevant code:
https://github.com/zopefoundation/zope.interface/blob/405017fef489ff9d517d0e86e6cb0e6a14fb9bd6/src/zope/__init__.py
Linkified link:
https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages
What version of Python and Zope/Addons I am using:
zope.interface==6.0
The text was updated successfully, but these errors were encountered: