You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Environment: Docker container built from python:2.7-slim-buster (Debian variant). Also verified on my own computer running Ubuntu 20.04.1 LTS eventlet version: >= 0.25.0 (I verified that the bug does not occur with ==0.24.1 but does occur with ==0.25.0. I also verified that it occurs with the latest master.) Output from uname -a:Linux c9efdf963b14 5.4.0-59-generic #65-Ubuntu SMP Thu Dec 10 12:01:51 UTC 2020 x86_64 GNU/Linux Python version: 2.7.18 pip freeze:
I have searched the previous issues and found no mention of this issue.
Description: In Python 2, we use a library which is designed to work across both Python 2 and Python 3 for now. It uses future.standard_library.install_aliases to do this. However, when using this library in tandem with eventlet, and importing eventlet.green.urllib, the aliases no longer work and the library fails with an ImportError.
Steps to reproduce: Run the following MWE:
fromfuture.standard_libraryimportinstall_aliasesinstall_aliases()
importeventlet.green.urllibfromurllib.parseimporturlparse# ImportError: No module named parse
Please let me know if more information or clarification is required! I tried to investigate this as thoroughly as I could but it's certainly possible that I missed something. Also, I saw that Python 2.7 support is deprecated (understandably so), so if this bug is deemed not worth fixing, it might be worth adding a notice to the affected versions.
The text was updated successfully, but these errors were encountered:
Hi, thanks for your reply! I understand that usually that is the case. However, install_aliases is supposed to add an alias to urlparse so that one can write code that works on both Python 2 and Python 3. For example, the following modified snippet runs fine in Python 2 (I should have mentioned this above, sorry):
I see, thanks for taking the time to read the issue nonetheless. I think we'll stick with the older version of eventlet mentioned above for now (given that the relevant code is contained inside a dependency), until (hopefully) upgrading to Python 3.
Environment: Docker container built from
python:2.7-slim-buster
(Debian variant). Also verified on my own computer running Ubuntu 20.04.1 LTSeventlet version: >= 0.25.0 (I verified that the bug does not occur with ==0.24.1 but does occur with ==0.25.0. I also verified that it occurs with the latest
master
.)Output from
uname -a
:Linux c9efdf963b14 5.4.0-59-generic #65-Ubuntu SMP Thu Dec 10 12:01:51 UTC 2020 x86_64 GNU/Linux
Python version: 2.7.18
pip freeze
:I have searched the previous issues and found no mention of this issue.
Description: In Python 2, we use a library which is designed to work across both Python 2 and Python 3 for now. It uses
future.standard_library.install_aliases
to do this. However, when using this library in tandem with eventlet, and importingeventlet.green.urllib
, the aliases no longer work and the library fails with anImportError
.Steps to reproduce: Run the following MWE:
Please let me know if more information or clarification is required! I tried to investigate this as thoroughly as I could but it's certainly possible that I missed something. Also, I saw that Python 2.7 support is deprecated (understandably so), so if this bug is deemed not worth fixing, it might be worth adding a notice to the affected versions.
The text was updated successfully, but these errors were encountered: