I have a question
When I ran this command heroku run python manage.py migrate
I got this error: ImportError: No module named crispy_forms
But on locally every things are doing well but my app is don't to run on Heroku please help me ?
I have a question
When I ran this command heroku run python manage.py migrate
I got this error: ImportError: No module named crispy_forms
But on locally every things are doing well but my app is don't to run on Heroku please help me ?
you can also do
heroku run pip freeze
that will give you a list of installed pip apps on heroku.. but ya also check your requirements.txt file
I had the same issue when running heroku run python manage.py migrate command. Here is what I did and solve the issue:
crispy_forms in the INSTALLED_APPS under settings.pypip install --upgrade django-crispy-forms or pip3 install --upgrade django-crispy-forms depends on the Python version you are using (pip3 is for Python version 3 and above)If the aboves didn't work, try Daniel Roseman's suggestion:
django-crispy-forms==1.6.1 (version number will change so verify yourself here https://github.com/django-crispy-forms/django-crispy-forms/blob/dev/CHANGELOG.md) to requirements.txt fileThis helped me and hope this will work for you as well. But don't forget to run (i) git add ., (ii) git commit -m "your comment", and (iii) git push heroku master before running heroku run python manage.py migrate command again.
if you haven't already, run this on your heroku platform:
pip install django-crispy-forms
remember that your local dependencies will not be installed automatically on your heroku dynos.