puiterwijk / flask-oidc

OpenID Connect support for Flask
BSD 2-Clause "Simplified" License
156 stars 218 forks source link

Fails with `ImportError: cannot import name TimedJSONWebSignatureSerializer` #3

Closed altryne closed 9 years ago

altryne commented 9 years ago

Just importing from flask_oidc import OpenIDConnect fails with

ImportError: cannot import name TimedJSONWebSignatureSerializer

And it seems that TimedJSONWebSignatureSerializer is not even included anymore in ItsDangerous anymore according to http://pythonhosted.org/itsdangerous/

SteelPangolin commented 9 years ago

Can you please run pip freeze on your development virtualenv and paste the list of package versions in here? The current master of ItsDangerous still has TimedJSONWebSignatureSerializer, so I'm not sure what's happening here. https://github.com/mitsuhiko/itsdangerous/blob/master/itsdangerous.py

SteelPangolin commented 9 years ago

I can't reproduce this, so I'm going to close it. Please let me know if you run into it again.

Jakepaker commented 2 years ago

Flask that run on my venv is version 2.1.1. That doesn't contain TimedJSONWebSignatureSerializer.

mmacata commented 2 years ago

Looks like it was removed in 2.0.0. In my case downgrading itsdangerous<=2.0.0 helped as a quick fix although a real solution is suggested in the linked changelog.

parthjoshi-pc commented 2 years ago

Just ran into this issue. Shouldn't this be reopened @SteelPangolin ?

frozenpandaman commented 1 year ago

Following. I'm still not sure how to fix this without just downgrading Flask...

mmacata commented 1 year ago

This is how we fixed it in actinia - I don't know if this helps because it is a specific use case.

abompard commented 1 year ago

Hey folks! We have forked and assumed maintainership of flask-oidc, with Patrick's agreement. The reference repo is now at https://github.com/fedora-infra/flask-oidc/. PyPI has been updated. There's a new version available, 2.0.x, that fixes this issue and rebases on Authlib. Some features have been dropped but it should be mostly compatible (see the changelog). Please open tickets in our tracker if you have issues upgrading.

chibuezeayogu commented 1 year ago
from itsdangerous.serializer import Serializer
from itsdangerous.exc import BadSignature, BadData