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
File "C:\Python34\lib\site-packages\jwt\api_jwt.py", line 61, in decode
payload, signing_input, header, signature = self._load(jwt)
File "C:\Python34\lib\site-packages\jwt\api_jws.py", line 138, in _load
raise DecodeError('Not enough segments')
File "C:\Python34\lib\site-packages\jwt\api_jws.py", line 135, in _load
signing_input, crypto_segment = jwt.rsplit(b'.', 1)
ValueError: need more than 1 value to unpack
It seems like api_jws expects token value to contain b'.'
But my token was just ZSuxk8aa8KAh5idJ
I had this same error, but when the token was actually not making it to the server-side (typo when setting the Authorization header on the client).
The access token (and thus the value of jwt, before the jwt.encode('utf-8') call in that class), should be valid a JWT. Try validating it here: https://jwt.io/.
I got this error while running your sample code.
It seems like api_jws expects token value to contain
b'.'
But my token was just
ZSuxk8aa8KAh5idJ
Any idea?
P.S. I just checked the pyjwt library, and it says that it needs comma-based token value.
http://pyjwt.readthedocs.io/en/latest/
The text was updated successfully, but these errors were encountered: