Opened 3 weeks ago
Closed 3 weeks ago
#36928 closed Bug (invalid)
django admin log model is missing makemigrations in 6.0 and 6.1 (dev)
| Reported by: | devnull | Owned by: | |
|---|---|---|---|
| Component: | contrib.admin | Version: | 6.0 |
| Severity: | Normal | Keywords: | |
| Cc: | devnull | Triage Stage: | Unreviewed |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
Hey,
I've noticed that the django admin log model is missing the makemigrations because it still uses a AutoField instead of the BigAutoField introduced in Django 6.0: https://docs.djangoproject.com/en/6.0/ref/settings/#default-auto-field. I've checked branch stable/6.0.x and main.
Is there a way to create the migration myself as a temporary workaround?
BR
Change History (2)
comment:1 by , 3 weeks ago
comment:2 by , 3 weeks ago
| Resolution: | → invalid |
|---|---|
| Status: | new → closed |
It's only the global setting DEFAULT_AUTO_FIELD that changed to BigAutoField in Django 6.0. As you noted, the admin still uses AutoField as specified in its AppConfig.
The apps.py shows this is on purpose: https://github.com/django/django/blob/main/django/contrib/admin/apps.py#L10 but the commit adding this line is from 2020: https://github.com/django/django/commit/b5e12d490af3debca8c55ab3c1698189fdedbbdb.