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

overrides: lock table before duplicate check #1594

Merged
merged 4 commits into from
Jun 2, 2021

Conversation

mastercactapus
Copy link
Member

@mastercactapus mastercactapus commented Jun 1, 2021

  • Identified the issue which this PR solves.
  • Read the CONTRIBUTING document.
  • Code builds clean without any errors or warnings.
  • Added appropriate tests for any new functionality.
  • All new and existing tests passed.
  • Added comments in the code, where necessary.
  • Ran make check to catch common errors. Fixed any that came up.

Description:
It's currently possible for duplicate/overlapping overrides to be entered if they are done simultaneously. This PR resolves the issue by adding a lock to the validation trigger.

A new smoketest was added for this case, removing line 8 of the new migration should cause the test to fail.

Copy link
Contributor

@arurao arurao left a comment

Choose a reason for hiding this comment

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

LGTM 🎉

@mastercactapus mastercactapus merged commit 9bb646e into master Jun 2, 2021
@mastercactapus mastercactapus deleted the prevent-duplicate-overrides branch June 2, 2021 14:55
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.

3 participants