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

Throw error if user tries to upload the same version twice #90

Merged
merged 1 commit into from
May 28, 2021

Conversation

andreasjansson
Copy link
Member

Signed-off-by: andreasjansson andreas@replicate.ai

Closes #73

@bfirsh
Copy link
Member

bfirsh commented May 27, 2021

Test failures are real!

@bfirsh
Copy link
Member

bfirsh commented May 27, 2021

Looks good otherwise!

Not important because it seems unlikely, but I don't think handles the case where two pushes happen simultaneously. Maybe it will just silently get overwritten with the one that gets written last, which seems reasonable, but this will cause two webhooks to get sent for the same ID which will throw an error.

@andreasjansson andreasjansson force-pushed the andreas/handle-repush branch 2 times, most recently from 16ed7fd to 3234f44 Compare May 27, 2021 22:34
Signed-off-by: andreasjansson <andreas@replicate.ai>
@andreasjansson
Copy link
Member Author

Looks good otherwise!

Not important because it seems unlikely, but I don't think handles the case where two pushes happen simultaneously. Maybe it will just silently get overwritten with the one that gets written last, which seems reasonable, but this will cause two webhooks to get sent for the same ID which will throw an error.

Yeah I think we can live with that for now at least.

Fixed tests.

@bfirsh
Copy link
Member

bfirsh commented May 28, 2021

@bfirsh bfirsh deleted the andreas/handle-repush branch May 28, 2021 18:28
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.

Throw error if version already exists
2 participants