Skip to content

fix(files): Fail when deleting all files fails with 404 error#1949

Merged
szokeasaurusrex merged 1 commit intomasterfrom
szokeasaurusrex/404-release-delete
Feb 20, 2024
Merged

fix(files): Fail when deleting all files fails with 404 error#1949
szokeasaurusrex merged 1 commit intomasterfrom
szokeasaurusrex/404-release-delete

Conversation

@szokeasaurusrex
Copy link
Copy Markdown
Member

For some reason, until now, 404 errors received special treatment when running the sentry-cli files delete --all command. Therefore, if for whatever reason, the files could not be deleted due to a 404 error, the command would fail silently. The only indication that anything went wrong would be that the "All files deleted" message would not be printed.

Instead, it would make more sense to print the error message from the Sentry API and fail with a nonzero status, since the CLI has likely failed to accomplish what the user intended for it to accomplish when running the command.

Or, is there any reason why we need to keep the special logic for 404 errors around?

@szokeasaurusrex szokeasaurusrex enabled auto-merge (squash) February 19, 2024 10:16
@szokeasaurusrex szokeasaurusrex self-assigned this Feb 19, 2024
@szokeasaurusrex szokeasaurusrex merged commit d40849a into master Feb 20, 2024
@szokeasaurusrex szokeasaurusrex deleted the szokeasaurusrex/404-release-delete branch February 20, 2024 13:49
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