Project

Profile

Help

Issue #6743

Installations migrating from 3.3.0 to 3.3.1 will be broken (without data loss)

Added by dalley over 1 year ago. Updated over 1 year ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
High
Assignee:
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
4. Urgent
Version:
3.3.1
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Sprint 72
Quarter:

Description

By modifying a prior migration, we accidentally created a mismatch between the schema we expect and the schema Django seems to interpret and enforce, presumably due to some kind of optimization being employed.

It seems that because Django sees that migration 0005 made the 'last_sync_revision_number' column nullable (it didn't, it was modified afterwards) [0], it ignores when migration 0009 tells Django to perform that migration later. Thus the 'last_sync_revision_number' column remains non-nullable.

This impacts Pulp users by throwing the following error when creating new RPM repositories.

django.db.utils.IntegrityError: null value in column "last_sync_revision_number" violates not-null constraint

[0] https://github.com/pulp/pulp_rpm/pull/1694/files#diff-8882c765a6805ada6c8a8bafe3e3e5b8

Associated revisions

Revision e468ab7f View on GitHub
Added by dalley over 1 year ago

Fix borked migration between 3.3.0 and 3.3.1+ schema.

closes: #6743 https://pulp.plan.io/issues/6743

Revision 49e89f82 View on GitHub
Added by dalley over 1 year ago

Fix borked migration between 3.3.0 and 3.3.1+ schema.

closes: #6743 https://pulp.plan.io/issues/6743 (cherry picked from commit e468ab7f305a21aa0be80f48148580e9ffab0f67)

Revision a40ec877 View on GitHub
Added by dalley over 1 year ago

Fix borked migration between 3.3.0 and 3.3.1+ schema.

closes: #6743 https://pulp.plan.io/issues/6743 (cherry picked from commit e468ab7f305a21aa0be80f48148580e9ffab0f67)

History

#1 Updated by dalley over 1 year ago

  • Description updated (diff)

#2 Updated by pulpbot over 1 year ago

  • Status changed from NEW to POST

#3 Updated by dalley over 1 year ago

  • Description updated (diff)
  • Assignee set to dalley

#4 Updated by dalley over 1 year ago

  • Status changed from POST to MODIFIED

#5 Updated by dalley over 1 year ago

#6 Updated by dalley over 1 year ago

#7 Updated by ttereshc over 1 year ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE
  • Sprint/Milestone set to Pulp RPM 3.3.2

Also available in: Atom PDF