Home > Software design >  ModuleNotFoundError: No module named 'collections.abc'; 'collections' is not a p
ModuleNotFoundError: No module named 'collections.abc'; 'collections' is not a p

Time:06-12

My code (python) works perfectly in local but not when I deploy it on Heroku.

This is the error

CodePudding user response:

You've got a file called collections.py in your /app folder. So it's trying to import it from there rather than the actual python-collections module. Rename yours to not clash with the names of python built-in modules, like my_collections.py, and retry.

  • Related