[Django] #30174: Forgotten migrations in Django 2.1.6

3 views
Skip to first unread message

Django

unread,
Feb 11, 2019, 6:22:23 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: | Owner: nobody
mjholtkamp |
Type: Bug | Status: new
Component: | Version: 2.1
contrib.auth | Keywords: 2.1.6 migration
Severity: Normal | auth
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 1
UI/UX: 0 |
-------------------------------------+-------------------------------------
Unless I'm mistaken, I think models were changed from 2.1.5 to 2.1.6 but
new migration files were not created.

This currently breaks our build because we check for 'forgotten'
migrations, so we have to stick to 2.1.5 or change our check to exclude
this migration.

== Steps to reproduce
{{{
python3 -m venv venv
source venv/bin/activate
pip install django
django-admin startproject mwe
cd mwe
python manage.py makemigrations
}}}

== Result
{{{
Migrations for 'auth':
/Users/michiel/tmmmp/venv/lib/python3.6/site-
packages/django/contrib/auth/migrations/0012_auto_20190211_1115.py
- Alter field name on group
}}}

== Expected result
{{{
No changes detected
}}}

== Suggested fix
run 'makemigrations', commit the file and re-publish :-)

--
Ticket URL: <https://code.djangoproject.com/ticket/30174>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Feb 11, 2019, 6:54:45 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: mjholtkamp | Owner: nobody
Type: Bug | Status: new
Component: contrib.auth | Version: 2.1
Severity: Normal | Resolution:
Keywords: 2.1.6 migration | Triage Stage:
auth | Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Ewald Moitzi):

Version 1.11.19 is also affected:


{{{
Migrations for 'admin':
/var/lib/python3.6/site-
packages/django/contrib/admin/migrations/0004_auto_20190211_1249.py
- Alter field action_flag on logentry
Migrations for 'auth':
/var/lib/python3.6/site-
packages/django/contrib/auth/migrations/0012_auto_20190211_1249.py


- Alter field name on group

- Alter field last_name on user
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/30174#comment:1>

Django

unread,
Feb 11, 2019, 7:02:21 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: mjholtkamp | Owner: nobody
Type: Bug | Status: new

Component: contrib.auth | Version: 2.1
Severity: Normal | Resolution:
Keywords: 2.1.6 migration | Triage Stage:
auth | Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Bruno Alla):

I noticed the same problem, but looking at the diff on GitHub, there
doesn't seem to be any model change:
https://github.com/django/django/compare/2.1.5...2.1.6

Was the wrong release published as 2.1?

--
Ticket URL: <https://code.djangoproject.com/ticket/30174#comment:2>

Django

unread,
Feb 11, 2019, 7:16:27 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: Michiel Holtkamp | Owner: nobody
Type: Bug | Status: new

Component: contrib.auth | Version: 2.1
Severity: Normal | Resolution:
Keywords: 2.1.6 migration | Triage Stage:
auth | Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Ewald Moitzi):

Replying to [comment:2 Bruno Alla]:


> I noticed the same problem, but looking at the diff on GitHub, there
doesn't seem to be any model change:
> https://github.com/django/django/compare/2.1.5...2.1.6
>

> Was the wrong release published as 2.1.6?

Looks like it, the missing auth migration for 1.11 wants to undo a change
that was made in the master branch
(https://github.com/django/django/commit/e81955401885a93a459bcc130642b6ea5bf4ba4d
#diff-49fc6cea24d46bdb27339c1aab392e32):
{{{
class Migration(migrations.Migration):

dependencies = [
('auth', '0011_update_proxy_permissions'),
]

operations = [
migrations.AlterField(
model_name='group',
name='name',
field=models.CharField(max_length=80, unique=True,
verbose_name='name'),
),
migrations.AlterField(
model_name='user',
name='last_name',
field=models.CharField(blank=True, max_length=30,
verbose_name='last name'),
),
]
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/30174#comment:3>

Django

unread,
Feb 11, 2019, 7:45:11 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: Michiel Holtkamp | Owner: nobody
Type: Bug | Status: new

Component: contrib.auth | Version: 2.1
Severity: Normal | Resolution:
Keywords: 2.1.6 migration | Triage Stage:
auth | Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by viktoradavid):

2.0.11 is affected as well - that means all the versions released today.
{{{
Migrations for 'admin':
/home/me/.virtualenvs/cms/lib/python3.7/site-
packages/django/contrib/admin/migrations/0004_auto_20190211_1228.py


- Alter field action_flag on logentry
Migrations for 'auth':

/home/me/.virtualenvs/cms/lib/python3.7/site-
packages/django/contrib/auth/migrations/0012_auto_20190211_1228.py


- Alter field name on group
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/30174#comment:4>

Django

unread,
Feb 11, 2019, 9:04:26 AM2/11/19
to django-...@googlegroups.com
#30174: Forgotten migrations in Django 2.1.6
-------------------------------------+-------------------------------------
Reporter: Michiel Holtkamp | Owner: nobody
Type: Bug | Status: closed
Component: contrib.auth | Version: 2.1
Severity: Normal | Resolution: duplicate

Keywords: 2.1.6 migration | Triage Stage:
auth | Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham):

* status: new => closed
* resolution: => duplicate


Comment:

Consolidating with #30175.

--
Ticket URL: <https://code.djangoproject.com/ticket/30174#comment:5>

Reply all
Reply to author
Forward
0 new messages