Trouble getting Django set up on Heroku using South - keep getting ProgrammingError: relation does not exist Trouble getting Django set up on Heroku using South - keep getting ProgrammingError: relation does not exist postgresql postgresql

Trouble getting Django set up on Heroku using South - keep getting ProgrammingError: relation does not exist


There's a circular import that should've been handled by just deferring the creation of api_userprofile, but because of how South handles transactions, it breaks.

So! Easiest way to make this work is to get syncdb to make all the tables and just fake the migration:

python manage.py syncdb --all

That gets us:

Synced: > django.contrib.admin > django.contrib.auth > django.contrib.contenttypes > django.contrib.sessions > django.contrib.messages > django.contrib.staticfiles > api > extapi > moodranker > recommender > south > rest_frameworkNot synced (use migrations): - 

Then fake the migrations:

python manage.py migrate --fake


Delete your migrations folder and then do

python manage.py makemigrations appnamepython manage.py migrate --run-syncdbpython manage.py migrate --fake appname