"Unknown column" exception after removing field in migration.
When removing field of base class model in my migration and than using RunPython
with subclass model query I face exception django.db.utils.OperationalError: (1054, "Unknown column 'bugapp_person.name' in 'field list'")
. It looks like during migrating, current migration state of submodel does not reflect field removal. Base class is alright though. Additionally, this happens only when at least one extra model with OTO field to base model exists.
This occurs in Django 1.8. I had no problem with any of 1.7.x (1.7.7 recently). Simplified snippet attached below runs smoothly with 1.7 and should reproduce the error under 1.8.
Description: |
modified (diff)
|
Has patch: |
set
|
Needs documentation: |
set
|
Needs tests: |
set
|
Owner: |
changed from nobody to Markus Holtermann
|
Severity: |
Normal → Release blocker
|
Status: |
new → assigned
|
Triage Stage: |
Unreviewed → Accepted
|
Cc: |
joostrijneveld@… added
|
Needs documentation: |
unset
|
Needs tests: |
unset
|
Triage Stage: |
Accepted → Ready for checkin
|
Resolution: |
→ fixed
|
Status: |
assigned → closed
|
Ok, it took me a while, but I can confirm that bug.
PR: https://github.com/django/django/pull/4447