-1

I am getting the error

WARNING: pyjwt 1.1.0 does not provide the extra 'crypto'

for Docker command

RUN pip install --no-cache /wheels/*

while installing PyJWT==1.7.1, Is there any solution to fix this warning?

Avin Mathew
  • 336
  • 11
  • 25

3 Answers3

2

PyJWT 1.7.1 was released at Dec 7, 2018.

Extra crypto was added to PyJWT on Oct 22, 2019 hence it's available in PyJWT 2.0+.

To use pyjwt[crypto] you need to install later version. Currently the latest is PyJWT 2.0.1.

phd
  • 82,685
  • 13
  • 120
  • 165
1

You can install pyjwt with the cryptographic Dependency with:

pip install pyjwt[crypto]

As seen in pyjwt's documentation

You can also separately install the required library with as seen on pyca/cryptography's documentation:

pip install cryptography
Gab
  • 3,404
  • 1
  • 11
  • 22
-1

In order to fix the following warning

WARNING: You are using pip version 20.1.1; however, version 21.0 is available. You should consider upgrading via the '/usr/local/bin/python -m pip install --upgrade pip' command.

I added the following code to Dockerfile

# upgrade pip
RUN pip install --upgrade pip

I just reverted adding this and it now works correctly, although I still have the pip version warning.

Avin Mathew
  • 336
  • 11
  • 25