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

Consistently return Boolean for delete methods #359

Merged
merged 1 commit into from
Sep 25, 2024
Merged

Conversation

mattt
Copy link
Contributor

@mattt mattt commented Sep 25, 2024

Resolves #356

When deleting a model, Replicate's API returns with a 204 and an empty response body. The client library fails to decode this and raises and exception.

This PR updates the replicate.models.delete method to return bool instead to indicate success. It also harmonizes the other delete methods for deployments and files to do the same.

Signed-off-by: Mattt Zmuda <mattt@replicate.com>
@mattt mattt merged commit 67a87c5 into main Sep 25, 2024
6 checks passed
@mattt mattt deleted the mattt/handle-204 branch September 25, 2024 19:31
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.

Error when succesfully deleting model without version
1 participant