ImportError: cannot import name ‘Iterable’ from ‘collections’ in Python

The Iterable abstract class was removed from collections in Python 3.10. See the deprecation note in the 3.9 collections docs. In the section Removed of the 3.10 docs, the item

  • Remove deprecated aliases to Collections Abstract Base Classes from the collections module. (Contributed by Victor Stinner in bpo-37324.)

is what results in your error.

You can use Iterable from collections.abc instead, or use Python 3.9 if the problem is in a dependency that can’t be updated.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)