pythonkc / pythonkc-com

Django app for pythonkc.com.
18 stars 15 forks source link

Run migrations fails during re-provisioning #25

Open clebio opened 8 years ago

clebio commented 8 years ago

When issuing vagrant provision on an existing VM, I get the following failure. Can we make the Run migrations task resilient to re-runs?

==> pykcdotdev: Running migrations:
==> pykcdotdev:   Rendering model states... DONE
==> pykcdotdev:   Applying admin.0001_initial...
==> pykcdotdev: :stderr: Traceback (most recent call last):
==> pykcdotdev:   File "manage.py", line 11, in <module>
==> pykcdotdev:     execute_from_command_line(sys.argv)
==> pykcdotdev:   File "/home/vagrant/virtualenvs/pythonkc/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 338, in execute_from_command_line
==> pykcdotdev:     utility.execute()
...
==> pykcdotdev:   File "/home/vagrant/virtualenvs/pythonkc/local/lib/python2.7/site-packages/django/db/backends/sqlite3/base.py", line 316, in execute
==> pykcdotdev:     return Database.Cursor.execute(self, query)
==> pykcdotdev: django.db.utils.OperationalError: table "django_admin_log" already exists
==> pykcdotdev: