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

ImportError: cannot import name 'Iterable' from 'collections' #5

Open
t-tte opened this issue Apr 19, 2022 · 1 comment · May be fixed by #6
Open

ImportError: cannot import name 'Iterable' from 'collections' #5

t-tte opened this issue Apr 19, 2022 · 1 comment · May be fixed by #6

Comments

@t-tte
Copy link

t-tte commented Apr 19, 2022

When using Python version 3.9 and later,

from causalgraphicalmodels import CausalGraphicalModel

results in

ImportError: cannot import name 'Iterable' from 'collections'

The following fix is described here:

try:
    # Python <= 3.9
    from collections import Iterable
except ImportError:
    # Python > 3.9
    from collections.abc import Iterable
@EAly
Copy link

EAly commented Jul 16, 2022

I'm getting the same import error for Python 3.10
I tried to run from collections.abc import Iterable before from causalgraphicalmodels import CausalGraphicalModel but I still get the same error

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

Successfully merging a pull request may close this issue.

2 participants