[NO-JIRA] Surface Percy silent failures as CI errors#4541
Open
Richard-Shen (RichardSyq) wants to merge 5 commits into
Open
[NO-JIRA] Surface Percy silent failures as CI errors#4541Richard-Shen (RichardSyq) wants to merge 5 commits into
Richard-Shen (RichardSyq) wants to merge 5 commits into
Conversation
Percy CLI exits 0 even when it fails internally (missing token, API errors, build not created). This causes the PercyTests job to show green while actually failing. Add pre-validation of PERCY_TOKEN and post-run log inspection to exit 1 on known failure patterns. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Visit https://backpack.github.io/storybook-prs/4541 to see this build running in a browser. |
|
Visit https://backpack.github.io/storybook-prs/4541 to see this build running in a browser. |
|
Visit https://backpack.github.io/storybook-prs/4541 to see this build running in a browser. |
Replace shell-based log parsing with Percy's built-in PERCY_RAISE_ERROR env var, which causes Percy CLI to exit non-zero on internal errors rather than silently succeeding. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Visit https://backpack.github.io/storybook-prs/4541 to see this build running in a browser. |
PERCY_RAISE_ERROR does not work for token/build-creation failures in Percy CLI 1.31.x — the process still exits 0 even when it prints "Build not created". Instead: 1. Pre-check that PERCY_TOKEN is non-empty 2. Use set -o pipefail to catch npm script failures 3. Grep for the definitive "[percy] Build not created" message This is narrowly targeted at the exact failure pattern observed in CI (Percy starts, processes snapshots, but cannot create the build). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Visit https://backpack.github.io/storybook-prs/4541 to see this build running in a browser. |
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
PERCY_TOKENand post-run log inspection toexit 1on known failure patternsWhat changed
The Percy Test step now:
PERCY_TOKENis set before running — fails immediately if emptyBuild not created,Failed to create build,Error:)Test plan
PERCY_TOKENcauses the job to fail with a clear error message🤖 Generated with Claude Code