-
-
Notifications
You must be signed in to change notification settings - Fork 489
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
simple-history 2.6.0 generates a migration while 2.5.1 doesn't #512
Comments
originally reported in: https://stackoverflow.com/questions/54177838/ depends on ./manage.py migrate exiting with non-zero: django/django#10844 Also see: jazzband/django-simple-history#512
Found the issue @atodorov ! It's this line here https://github.com/treyhunner/django-simple-history/pull/462/files#diff-db0d12c32869d48141bfca2c94659322L203. In adding the deconstruct method to that code, we accidentally got rid of that line. DSH still supports foreign keys to the same object, but we accidentally got rid of support for using |
originally reported in: https://stackoverflow.com/questions/54177838/ Also see: jazzband/django-simple-history#512
@rossmechanic thank you for the lightning fast reaction!
This WA works for me and doesn't produce any more migrations. Unfortunately we do have a live version of Kiwi TCMS out there which customers have deployed and are hitting this issue. As we are shipping with pinned dependencies in our Docker image even if you do release a fix there's not much to be done on our end except publishing a new docker image. Sigh. |
originally reported in: https://stackoverflow.com/questions/54177838/ Also see: jazzband/django-simple-history#512
@atodorov sorry about that! That should have been caught in automated tests, but evidently whoever wrote that feature originally didn't test it... I do have a PR up that should be merged by tomorrow, and I've been planning to have a new release by end of week. Sorry for the additional work 😞 |
originally reported in: https://stackoverflow.com/questions/54177838/ Also see: jazzband/django-simple-history#512
Describe the bug
Kiwi TCMS uses simple-history as dependency. Until recently we had version 2.5.1 and we've upgraded to 2.6.0. The problem is that with 2.5.1 ./manage.py migrate/makemigrations doesn't detect any new changes but with 2.6.0 it does.
Here's how the initial migration looks like:
Here's what
makemigrations
produces with 2.6.0:The only difference I see is how we reference the
on_delete
constraint.To Reproduce
Steps to reproduce the behavior:
Repeat the above with 2.5.1 instead and the last step tells you there are no changes detected
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: