Repository navigation
ci: name each needed job in the frontend deploy condition - #338
Merged
Merged
Conversation
#337 did not work. In a job's `if`, `needs.*.result` also holds skipped ancestors, so `!contains(needs.*.result, 'skipped')` is false on every push (reproduced on GitHub, run 47297480733). The condition now names each job in `needs`, and a test fails when the two lists differ. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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.
#337 did not work
Its push run (47295529154) was green and skipped
Deploy frontendagain, with all seven jobs inneedssuccessful. I had checked the expression with a local stand-in that assumedneeds.*.resultholds only direct needs. That was wrong.Cause, reproduced on GitHub
A throwaway workflow on a scratch branch (no secrets, no deploy; branch deleted) copied the job graph: run 47297480733.
contains(needs.*.result, 'skipped')ran, although both its direct needs succeeded: in a job'sif,needs.*.resultalso holds skipped ancestors.needs.x.result == 'success') ran, including the called workflow's job and itsgithub.refcondition.A step's
toJSON(needs)in the same run showed direct needs only.Change
deploy-frontendnames each job inneeds, the shape Homiio already deploys with. Because a forgotten name would let a failed job deploy,deployGate.test.jsfails when the two lists differ.The backend
Deployjob is unchanged. Merging this deploys the web app frommain, including #335.Verification
The probe above; the new test passes, and fails when a job is added to
needswithout its line;test:gatespasses. The probe did not include a matrix job (city3d), so the push run after merge is the final check.🤖 Generated with Claude Code