-
Notifications
You must be signed in to change notification settings - Fork 222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Broken migrations to 0.9.0a1 #153
Comments
How do you test it? Anyway, I've tried to migrate db from lfs 0.7 to latest tip and get some errors about "django.db.utils.OperationalError: no such column: customer_customer.dsa_object_id". I did it by installing lfs-buildout-development and migrating lfs.db (sqlite) from lfs 0.7 install. Migrations were tested but when it was still using django 1.4. |
I tried also to migrate my "production" postgres db, but here I ran in other errors like: django.db.utils.IntegrityError: duplicate key value violates unique constraint "addresses_baseaddress_pkey" I added in migrate_to_09 def: then I received other errors again. There are also some conflicts with the models in 0.9.0a1 in some fields which must be created after by migrations(South). |
I've found that removal of stale content types during run of 'migrate' command caused some errors during migration (ones about not existing columns). I've added a 'interactive=False' to the call to migrate command to fix it and migration works for me with sqlite db now. I've not been able to reproduce sequence problem but haven't tried it with postgres. If cursor.execute("SELECT setval('addresses_baseaddress_id_seq', (SELECT MAX(id) FROM addresses_baseaddress)+1)") fixes it then please provide a pull request or at least a line number where it should be inserted. |
Ok Maciej, I'll test it with my postgress db with my production data and On Mon, Aug 25, 2014 at 10:13 PM, Maciej Wiśniowski <
|
If you install and "initiate" from scratch django-lfs==0.7 then you'are not able to migrate it to 0.9.0a1, you'll receive a lot of errors in migrate_to_09 def:
django.db.utils.OperationalError: no such column: customer_customer.sa_content_type_id
and...
TypeError: 'NoneType' object has no attribute 'getitem'
and...
django.db.utils.OperationalError: no such table: core_application
and...
django.db.utils.IntegrityError: null value in column "price" violates not-null constraint
and so on...
have anyone tested these migrations at least once?
The text was updated successfully, but these errors were encountered: