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

AttributeError module 'collections' has no attribute 'Iterator': Python 3.10 compatibility #73

Open
jklemm opened this issue Nov 7, 2022 · 0 comments

Comments

@jklemm
Copy link

jklemm commented Nov 7, 2022

After upgrade to python 3.10, we're getting an error:

jsonpickle/util.py in is_iterator at line 338

def is_iterator(obj):
    is_file = False
    if not PY3:
        is_file = isinstance(obj, __builtin__.file)
    return (isinstance(obj, collections.Iterator) and
            not isinstance(obj, io.IOBase) and not is_file)

AttributeError
module 'collections' has no attribute 'Iterator'

Look like the jsonpickle==0.7.1 is not compatible with python 3.10.

Python 3.10 changes the collections import, read more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant