Skip to content

Add missing migration for Partners & AssignedReviewers#4804

Open
wes-otf wants to merge 1 commit intomainfrom
fix/add-assignedreviewers-migration
Open

Add missing migration for Partners & AssignedReviewers#4804
wes-otf wants to merge 1 commit intomainfrom
fix/add-assignedreviewers-migration

Conversation

@wes-otf
Copy link
Copy Markdown
Contributor

@wes-otf wes-otf commented Apr 7, 2026

Related to #4790. I missed an edge case where an AssignedReviewer was also a Partner, in which the migrations would fail as the type attribute is protected in the model. This moves all types of partner to reviewer.

Test Steps

  • Ensure AssignedReviewers with type of partner get migrated to reviewer and that all migrations pass successfully.

@wes-otf wes-otf requested a review from frjo April 7, 2026 16:16
@frjo
Copy link
Copy Markdown
Member

frjo commented Apr 7, 2026

Running this:

git switch main
uv run python manage.py migrate
git switch fix/add-assignedreviewers-migration
uv run python manage.py migrate

I get this error:

django.db.migrations.exceptions.InconsistentMigrationHistory: Migration users.0028_remove_partner_group is applied before its dependency funds.0134_change_partner_assigned_reviewers_role on database 'default'.

@frjo
Copy link
Copy Markdown
Member

frjo commented Apr 7, 2026

I think we can make changes to 0028_remove_partner_group.py‎ directly.

The few system that have applied it likely do not have this edgecase so do not need fixes.

Copy link
Copy Markdown
Member

@frjo frjo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comments above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants