Exit non-zero on failed deploys, add deploy --watch#19
Merged
stevethomas merged 3 commits intomainfrom Apr 27, 2026
Merged
Conversation
deploy:status now returns exit code 1 if any displayed deployment ended in Failed or Stopped, so CI scripts can fail correctly. deploy gains a --watch (-w) option that chains straight into deploy:status --watch once the deploy steps complete, propagating its exit code. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
BuildCommand, StageCommand and SyncCommand still declared handle(): void, breaking covariance after SteppedCommand::handle() moved to int. Bumped each to int and propagated parent's return. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Symfony exposes named constants for the canonical exit codes; using them reads better than bare 0/1 at the return sites. Co-Authored-By: Claude Opus 4.7 (1M context) <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.
Summary
deploy:statusnow exits 1 when any displayed deployment ended inFailedorStopped, so CI scripts can fail loudly on a bad deploy.deploy <env>gains a--watch(-w) flag — once the deploy steps finish, it chains straight intodeploy:status --watchand propagates its exit code.SteppedCommand::handle()switched tointreturn so subclasses can chain a non-zero exit code through.Test plan
yolo deploy:status <env>against a healthy env exits 0yolo deploy:status <env>against an env whose latest CodeDeploy isFailedexits 1yolo deploy <env> --watchruns deploy as normal then drops into the polling status table, exits 0 when all greenyolo deploy <env> --watchexits 1 if any group endsFailed🤖 Generated with Claude Code