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

Python 3.4 not working with rsa version upgrade #548

Closed
aabmass opened this issue Jun 24, 2020 · 3 comments
Closed

Python 3.4 not working with rsa version upgrade #548

aabmass opened this issue Jun 24, 2020 · 3 comments
Assignees
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@aabmass
Copy link

aabmass commented Jun 24, 2020

Environment details

  • OS: Linux
  • Python version: 3.4
  • pip version: 19.1.1
  • google-auth version: 1.18.0

Steps to reproduce

python3.4 -m venv venv
source venv/bin/activate
pip install --upgrade pip
pip install google-auth

# importing google auth causes the issue
python -c "import google.auth.crypt"
Traceback (most recent call last):
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/google/auth/crypt/rsa.py", line 20, in <module>
    from google.auth.crypt import _cryptography_rsa
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/google/auth/crypt/_cryptography_rsa.py", line 22, in <module>
    import cryptography.exceptions
ImportError: No module named 'cryptography'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/google/auth/crypt/__init__.py", line 43, in <module>
    from google.auth.crypt import rsa
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/google/auth/crypt/rsa.py", line 27, in <module>
    from google.auth.crypt import _python_rsa
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/google/auth/crypt/_python_rsa.py", line 28, in <module>
    import rsa
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/rsa/__init__.py", line 24, in <module>
    from rsa.key import newkeys, PrivateKey, PublicKey
  File "/usr/local/google/home/aaronabbott/tmp/venv3.4/lib/python3.4/site-packages/rsa/key.py", line 35, in <module>
    import typing
ImportError: No module named 'typing'

rsa 4.1 drops python 2 and 3.4 support. The new version that google-auth is using tries to import typing.

@busunkim96
Copy link
Contributor

Thanks for filing an issue! Given that 3.4 is now EOL I opened #549 to drop it from our list of supported versions. I also tweaked #544 to make the pin on RSA more specific

@aabmass
Copy link
Author

aabmass commented Jun 25, 2020

Awesome, thank you for the quick response!

@busunkim96 busunkim96 added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. and removed triage me I really want to be triaged. labels Jun 26, 2020
@tseaver
Copy link
Contributor

tseaver commented Jul 21, 2020

Via #544.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

4 participants