Opened 10 years ago

Closed 10 years ago

#24443 closed Bug (invalid)

Changing upload_to on a filefield creates a migration despite not changing the database at all

Reported by: Greg Brown Owned by: nobody
Component: Migrations Version: 1.7
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

upload_to is commonly set in django settings, and changing the setting generates a "Your models have changes that are not yet reflected in a migration..." warning until you create an (effectively no-op) migration. This really shouldn't trigger a migration, because upload_to is solely used to generate a file path, and doesn't change the underlying field at all.

It's not much of a problem for local apps, you just end up with extra migrations, but it happens with 3rd-party apps too.

Change History (1)

comment:1 by Tim Graham, 10 years ago

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.
Back to Top