Closed mgedmin closed 4 years ago
This will affect a bunch of other zopefoundation projects as well, unless Python 3.9 walks back the deprecations.
$ rg -l base64.*codestring|sort
AccessControl/src/AccessControl/userfolder.py
keas.build/src/keas/build/base.py
keas.build/src/keas/build/build.py
keas.build/src/keas/build/install.py
keas.build/src/keas/build/package.py
Products.CMFCore/Products/CMFCore/CookieCrumbler.py
Products.CMFCore/Products/CMFCore/utils.py
Products.MIMETools/src/Products/MIMETools/tests.py
Products.PluggableAuthService/Products/PluggableAuthService/plugins/CookieAuthHelper.py
Products.PluggableAuthService/Products/PluggableAuthService/plugins/tests/test_CookieAuthHelper.py
z3c.authenticator/src/z3c/authenticator/_compat.py
z3c.json/src/z3c/json/transport.py
z3c.soap/z3c/soap/README.txt
ZODB/src/ZODB/_compat.py
zope2docs/docs/zdgbook/Security.rst
zope.app.i18n/src/zope/app/i18n/browser/synchronize.py
zope.app.testing/src/zope/app/testing/functional.py
Zope/docs/zdgbook/Security.rst
zope.session/src/zope/session/session.py
zope.testbrowser/src/zope/testbrowser/_compat.py
zope.xmlpickle/src/zope/xmlpickle/ppml.py
ZServer/src/webdav/client.py
ZServer/src/webdav/tests/testPUT_factory.py
ZServer/src/ZServer/FCGIServer.py
ZServer/src/ZServer/FTPRequest.py
ZServer/src/ZServer/medusa/http_server.py
ZServer/src/ZServer/Testing/doctest_functional.py
ZServer/src/ZServer/Testing/functional.py
Reverting is being discussed on python-dev.
- Removed tostring/fromstring methods in array.array and base64 modules
It's not clear to me if that's supposed to include encodestring
though (I'm not fully current on the discussion though).
I'll try to look into this issue this week on Alpine City Sprint.
I did not manage to look into the issue.
I have created a PR #11 for this. The import is not used anywhere so I removed it.
To add more towards reversion the function was removed in python 3.9 which is in rc1 as of now. So the reversion to bring back encodestring was not done.
encodestring
is still missing on 3.9, see https://github.com/python/cpython/blob/3.9/Lib/base64.py.
So we'll have to fix the packages in the list provided by @mgedmin. (Leaving this issue closed as it is fixed for this particular package.)
Python 3.9 removes a bunch of deprecated functions, and base64.encodestring happens to be one of them.
zope.app.i18n.browser.synchronize tries to
from base64 import encodestring
, which now fails.