Add --fail to curl calls so a failed SignServer request fails the step#9
Merged
Merged
Conversation
None of the curl invocations used --fail, so an HTTP error response (e.g. a 4xx/5xx from SignServer or a proxy in front of it) gets written straight to the output file, and curl exits 0. The action then reports success and uploads the error response body as if it were the signed artifact, which is confusing to debug downstream. Adding --fail makes curl (and the step) actually fail on a non-2xx response. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
hanna-hansson
approved these changes
Jul 8, 2026
hanna-hansson
left a comment
Collaborator
There was a problem hiding this comment.
Code: looks good
Tests: tested with new workflow tests that will be added in separate PR
Docs: not needed
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.
Summary
None of the four
curlinvocations use--fail. If SignServer (or a proxy in front of it) returns an HTTP error, curl writes that error response body straight to the output file and still exits 0. The action then reports success and uploads the error page/body as if it were the signed artifact — which is a confusing thing to debug downstream (we hit this ourselves: an nginx 400 page got uploaded in place of a signed jar).Fix
Add
--failto all four curl calls, so a non-2xx response actually fails the step instead of silently producing a bad artifact.Test plan
--failadded, curl now exits non-zero on the same request🤖 Generated with Claude Code