I am trying to upgrade from Django 1.6.7 to Django 1.7.1, so I have been trying to migrate my app.
I have followed the django docs here.
I deleted the south from my installed apps.
In the migration directory, I delete the numbered migration files and the .pyc files but I kept the directory & __ init__.py file.
I then run :
python manage.py makemigrations your_app_name
I receive the following confirmation message:
Migrations for 'your_app_name':
0001_initial.py:
- Create model UserProfile
Next I run:
python manage.py migrate your_app_name
I received the following error:
CommandError: App 'your_app_name' does not have migrations (you cannot selectively sync unmigrated apps)
As per the docs, I also ran:
python manage.py migrate --fake your_app_name
I received the same error message:
CommandError: App 'your_app_name' does not have migrations (you cannot selectively sync unmigrated apps)
Can anyone shed some light on why this will not work for me?
admin app is used with your application: the migrations directory for this app is available at site-packages/django/contrib/admin/migrations , but migrations from apps that you created, are all stored inside each app folder.
Migrations are not required. They can be useful for creating and tracking database changes via code, but Django applications will run properly without them.
I noticed that only those apps that actually contain a migrations
folder that contain a file __init__.py
are recognized by migrations. IE having only models.py in your app is not enough.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With