Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: remove unapplicable conditional unique constraint on subsidy #167

Merged
merged 1 commit into from
Oct 31, 2023

Conversation

iloveagent57
Copy link
Contributor

ENT-7891 | MySQL has never supported conditional unique constraints. This commit removes a conditional unique constraint declared in the subsidy model's Meta class. It also has a no-op migration for same. Lastly, adds a migration for historical subsidy records from upgraded django-simple-history.

Description

Describe in a couple of sentences what this PR adds

Testing instructions

  1. Use make db-shell-8 to shell into mysql and run show create table subsidy;. Note there is no unique constraint corresponding to what's stated in the model.
  2. Run ./manage.py migrate in an app-shell to run migrations.
  3. In your db shell again, look at the subsidy table/indices and note there are no changes.

Merge checklist

  • All reviewers approved
  • CI build is green
  • Documentation updated (not only docstrings)
  • Commits are squashed

ENT-7891 | MySQL has never supported conditional unique constraints.
This commit removes a conditional unique constraint declared
in the subsidy model's Meta class.  It also has a no-op migration for same.
Lastly, adds a migration for historical subsidy records from
upgraded django-simple-history.
@iloveagent57 iloveagent57 force-pushed the aed/subsidy-uniqueness branch from ecfd36d to 6548ef3 Compare October 31, 2023 13:26
@iloveagent57 iloveagent57 merged commit 85dd080 into main Oct 31, 2023
7 checks passed
@iloveagent57 iloveagent57 deleted the aed/subsidy-uniqueness branch October 31, 2023 13:35
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