Changes between Initial Version and Version 2 of Ticket #27422
- Timestamp:
- Nov 2, 2016, 12:51:36 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #27422 – Description
initial v2 1 I am using django-social-auth and a custom User model. I changed my User model to use a BigInteger `id` field. Everything looked ok, and I pushed into production, then started getting not-super-informative exceptions about `integer out of range`. I tracked it down to this bug—specifically, I ha d a django-social-auth model with a foreignkey to User—and was able to reproduce it using a clean Django project. Thisshould either work correctly or raise an error.1 I am using django-social-auth and a custom User model. I changed my User model to use a BigInteger `id` field. Everything looked ok, and I pushed into production, then started getting not-super-informative exceptions about `integer out of range`. I tracked it down to this bug—specifically, I have a django-social-auth model with a foreignkey to User—and I was able to reproduce it on a clean Django project. This kind of migration should either work correctly or raise an error. 2 2 3 3 Steps to reproduce: 4 4 1. Create Model A 5 5 2. Create Model B with a ForeignKey to Model A 6 3. Alter the type of the ForeignKey on B, e.g. making it a BigInteger6 3. Alter the type of the primary key on A, e.g. making it a BigInteger 7 7 4. manage.py makemigrations and migrate 8 8