Closed atodorov closed 2 years ago
I've got a CI job to detect missing migrations. It failed with Django==4.0.1 and django-contrib-comments==2.1.0.
The test itself is
./manage.py migrate ./manage.py makemigrations --check
which produced the following:
Migrations for 'django_comments': /home/senko/.virtualenvs/kiwi_django3/lib/python3.8/site-packages/django_comments/migrations/0005_alter_comment_content_type_alter_comment_user.py - Alter field content_type on comment - Alter field user on comment
$ cat 0005_alter_comment_content_type_alter_comment_user.py # Generated by Django 4.0.1 on 2022-01-26 11:25 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('contenttypes', '0002_remove_content_type_name'), migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('django_comments', '0004_add_object_pk_is_removed_index'), ] operations = [ migrations.AlterField( model_name='comment', name='content_type', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='content_type_set_for_%(class)s', to='contenttypes.contenttype', verbose_name='content type'), ), migrations.AlterField( model_name='comment', name='user', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='%(class)s_comments', to=settings.AUTH_USER_MODEL, verbose_name='user'), ), ]
Solved in #181
I've got a CI job to detect missing migrations. It failed with Django==4.0.1 and django-contrib-comments==2.1.0.
The test itself is
which produced the following: