django app app crashing when opening on heroku

Viewed 16

I'm trying to open my heroku app but i keep getting the 'heroku logs --tail' error.

I checked the logs and the only error I can see is:

'ImportError: cannot import name '_sanitize_token' from 'django.middleware.csrf' (/app/.heroku/python/lib/python3.10/site-packages/django/middleware/csrf.py)'

FYI, I had some issue with the _sanitize_token when trying to run my server with manage.py before deploying. I had to change some settings in tastypies authentication:

original(wouldn't let me run server): from django.middleware.csrf import _sanitize_token

amended(this let me run the server): import django.middleware.csrf

Now, I don't know wether the error above is actually causing the crash or if i should be looking into this: at=error code=H10 desc="App crashed"

TYIA for any help on this

0 Answers
Related