<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, May 11, 2020 at 5:04 AM Tatiana Tereshchenko <<a href="mailto:ttereshc@redhat.com">ttereshc@redhat.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Dennis,  <div>FWIW, I believe there are a couple of problems here but neither of them is related to your advice to manually modify a migration. <div>Problem #1.  `django-admin makemigrations` was run, so this 0009_auto_... migration got created. I think the installer doesn't run this command, or does it?<br></div></div></div></blockquote><div>The installer does not run makemigrations.</div><div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div></div></div><div>Problem #2. The migration 0008 was not in sync with the model, so makemigraitons will create a new migraiton if run. Fixed in 3.3.1. <a href="https://pulp.plan.io/issues/6665" target="_blank">https://pulp.plan.io/issues/6665</a></div></div></blockquote><div>Great, then 3.3.1 as the current GA should resolve it. <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>Tanya</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, May 8, 2020 at 11:15 PM Bin Li (BLOOMBERG/ 120 PARK) <<a href="mailto:bli111@bloomberg.net" target="_blank">bli111@bloomberg.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="white-space:pre-wrap;font-size:small;font-family:"Courier New",Courier,"BB.FixedWidth"">No idea where it came from. The timestamp is from 4/25. I run pip uninstall pulp-rpm and it didn't remove it.<div><br></div><div># ls -ld /opt/utils/venv/pulp/3.7.3/lib/python3.7/site-packages/pulp_rpm/app/migrations/0009_auto_20200425_1932.py</div><div>-rw-rw-r-- 1 pulp mse-python 492 Apr 25 15:32 /opt/utils/venv/pulp/3.7.3/lib/python3.7/site-packages/pulp_rpm/app/migrations/0009_auto_20200425_1932.py</div><div><br></div><div># more /opt/utils/venv/pulp/3.7.3/lib/python3.7/site-packages/pulp_rpm/app/migrations/0009_auto_20200425_1932.py</div><div># Generated by Django 2.2.12 on 2020-04-25 19:32</div><div><br></div><div>from django.db import migrations, models</div><div><br></div><div><br></div><div>class Migration(migrations.Migration):</div><div><br></div><div>    dependencies = [</div><div>        ('rpm', '0008_advisory_pkg_sumtype_as_int'),</div><div>    ]</div><div><br></div><div>    operations = [</div><div>        migrations.AlterField(</div><div>            model_name='updatecollectionpackage',</div><div>            name='sum_type',</div><div>            field=models.PositiveIntegerField(choices=[(0, 0), (1, 1), (2, 2), (3, 3), (4, 4), (5, 5), (6, 6), (7, 7)], null=True),</div><div>        ),</div><div><br><br><div style="font-size:small;font-family:"Courier New",Courier,"BB.FixedWidth""><div><div><div>From: <a href="mailto:ggainey@redhat.com" target="_blank">ggainey@redhat.com</a> At: 05/08/20 16:21:45</div>To: <a href="mailto:bli111@bloomberg.net" target="_blank"> Bin Li (BLOOMBERG/ 120 PARK ) </a><br>Cc: <a href="mailto:pulp-list@redhat.com" target="_blank"> pulp-list@redhat.com</a><br>Subject: Re: [Pulp-list] 3.3.1 migration error</div><br></div><div style="background:white none repeat scroll 0% 0%;color:black;font-family:Arial,"BB.Proportional";font-size:small;white-space:normal"><div><blockquote><div dir="ltr"><div dir="ltr">Hey there!</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, May 8, 2020 at 3:53 PM Bin Li (BLOOMBERG/ 120 PARK) <<a href="mailto:bli111@bloomberg.net" target="_blank">bli111@bloomberg.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="font-size:small;font-family:"Courier New",Courier,"BB.FixedWidth";white-space:pre-wrap"><div>Hi All,</div><div>Getting an error to upgrade from 3.3.  run 'python manage.py makemigrations --merge' gave more errors. Anyidea how this can be fixed?</div><div><br></div>TASK [pulp-database : Run database auth migrations] **********************************************************************************************************<div>fatal: [pulp3-2]: FAILED! => {"changed": true, "cmd": ["/opt/utils/venv/pulp/3.7.3/bin/django-admin", "migrate", "auth", "--no-input"], "delta": "0:00:03.534845", "end": "2020-05-08 15:44:20.362670", "msg": "non-zero return code", "rc": 1, "start": "2020-05-08 15:44:16.827825", "stderr": "CommandError: Conflicting migrations detected; multiple leaf nodes in the migration graph: (0009_revision_null, 0009_auto_20200425_1932 in rpm).\nTo fix them run 'python manage.py makemigrations --merge'", "stderr_lines": ["CommandError: Conflicting migrations detected; multiple leaf nodes in the migration graph: (0009_revision_null, 0009_auto_20200425_1932 in rpm).", "To fix them run 'python manage.py makemigrations --merge'"], "stdout": "", "stdout_lines": []}</div></div></blockquote><div><br></div><div>Where did migration "0009_auto_20200425_1932" come from? Looks like it's conflicting with the delivered 0009_revision_null and causing your problem.</div><div><br></div><div>G</div></div>-- <br><div dir="ltr"><div dir="ltr"><div>Grant Gainey</div><div>Principal Software Engineer, Red Hat System Management Engineering</div></div></div></div></blockquote><br></div></div></div></div></div></div>_______________________________________________<br>
Pulp-list mailing list<br>
<a href="mailto:Pulp-list@redhat.com" target="_blank">Pulp-list@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-list" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pulp-list</a></blockquote></div>
_______________________________________________<br>
Pulp-list mailing list<br>
<a href="mailto:Pulp-list@redhat.com" target="_blank">Pulp-list@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-list" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pulp-list</a></blockquote></div></div>