[Answered ]-Django inconsistency of uwsgi and dev servers

0👍

The issue here was Celery module, and definition in celery.py file in my project dir. In celery.py there is line:

os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'project.settings')

I have two sites running on the same project but settings files are different for each other. I defined in the line above, settings file for first site but tried to run second. That is why settings have been overriden.

2👍

If you’re sure that everything is same, try clearing pyc files.

find . -name "*.pyc" -delete # from your code directory

If I had a penny for everytime pyc files messed up things…

Leave a comment