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

Augur new cntrb insert fix #1977

Merged
merged 5 commits into from Sep 8, 2022
Merged

Conversation

ABrain7710
Copy link
Contributor

@ABrain7710 ABrain7710 commented Sep 8, 2022

This aims to fix this error:
Exception('<class \'sqlalchemy.exc.IntegrityError\'>([\'(psycopg2.errors.UniqueViolation) duplicate key value violates unique constraint "contributors-pk"\\nDETAIL: Key (cntrb_id)=(010017ac-bf00-0000-0000-000000000000) already exists.\\n\'])')

  1. Imported the IntegrityError from sqlalchemy.exc
  2. Add try excepts around blocks that execute the insert

Note: I created this branch from augur-new-dev which is why there are a bunch of additional things I didn't mention above. augur-new-dev was just merged, so all these extra commits are already in augur-new

Signed-off-by: Andrew Brain <61482022+ABrain7710@users.noreply.github.com>
Signed-off-by: Andrew Brain <61482022+ABrain7710@users.noreply.github.com>
Signed-off-by: Andrew Brain <61482022+ABrain7710@users.noreply.github.com>
Signed-off-by: Andrew Brain <61482022+ABrain7710@users.noreply.github.com>
@ABrain7710 ABrain7710 added the bug-fix Fixes a bug label Sep 8, 2022
@ABrain7710 ABrain7710 merged commit 01719b9 into augur-new Sep 8, 2022
@ABrain7710 ABrain7710 deleted the augur-new-cntrb-insert-fix branch October 22, 2022 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-fix Fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants