Handle empty JSON responses - #52
Merged
ericviana merged 1 commit intoJul 27, 2026
Merged
Conversation
Contributor
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
ericviana
added a commit
that referenced
this pull request
Jul 27, 2026
…#60) Publish runs on every push to main and unconditionally calls `npm publish`, so any merge that does not bump the version fails the run with: npm error You cannot publish over the previously published versions: 4.0.2. That just happened twice, on #52 and #58. The noise matters: a permanently red publish job is how blindpay-cli's genuinely broken publish went unnoticed for two and a half months and left npm three versions behind. This adds the same version guard already merged into blindpay-cli and blindpay-mcp, so an unchanged version is a no-op instead of a failure. Also tags and creates a GitHub release on publish. This repo has published up to 4.0.2 on npm and has zero git tags, so there is currently no way to see what shipped in a release from the repo alone. Two notes, neither addressed here: - `.changeset/` has around 20 accumulated changeset files and no workflow consumes them, so version bumps are effectively manual edits to package.json. Worth either wiring up `changeset version` or dropping changesets. - main currently carries the #52 and #58 fixes at an unbumped 4.0.2, so they are unreleased. The next version bump ships them. Claude-Session: https://claude.ai/code/session_01F1stiNzuNtJXoXtiW9ZCbs
Member
|
Thanks for the PR @samsamtrum! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The client currently calls
response.json()for every successful response, so empty successful responses fail while parsing the body. This can affect endpoints typed as returningvoid, such as delete calls.This change parses the response body as text first and returns
nullwhen the body is empty. It also adds a regression test for an empty successful delete response.