Skip to content

feat(cli): add stack restart - #6603

Merged
jgoux merged 3 commits into
developfrom
feat/stack-restart
Sep 14, 2026
Merged

jgoux merged 3 commits into
developfrom
feat/stack-restart

Conversation

@jgoux

@jgoux jgoux commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

Add supabase stack restart for an existing managed stack, selected by the current project, --stack, or --stack-id. It stops and starts the same stack using its saved effective configuration, preserving its identity, data, service exclusions, activation settings, and preparation policy.

Restart does not reload project configuration or explicitly prepare artifacts. Runtime startup reuses cached artifacts and may fetch missing ones according to the saved policy. A normal start still loads project configuration and applies only its current flags, so start --exclude studio followed by stop and a plain start restores Studio when enabled in project configuration.

Stacks without a saved configuration are directed to stack start before they can be restarted.

Reimplemented directly on develop using the current stack command infrastructure.

Supersedes #6512

@jgoux
jgoux requested a review from a team as a code owner September 14, 2026 13:10
@jgoux jgoux self-assigned this Sep 14, 2026

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 AI Review

All seven source findings were verified and deduplicated into six entries: four confirmed and two refuted. The confirmed issues are two minor behavioral/error-handling concerns and two coverage/help-text nits; no critical or major defect was verified.

Findings

Severity Location Category Sources Claim
🟡 MINOR apps/cli/src/commands/experimental/stack/restart/restart.handler.ts:146 behavior claude Restart can re-enable capabilities previously disabled through one-off stack start --exclude flags without warning.
🟡 MINOR apps/cli/src/commands/experimental/stack/restart/restart.handler.ts:75 error-handling claude+codex Known StackRuntimeError and StackCleanupError failures lose the actionable recovery guidance provided by sibling lifecycle commands.
⚪ NIT apps/cli/src/commands/experimental/stack/restart/restart.command.ts:8 help-text claude The --stack flag description does not state that omitting it targets the current project's stack.
⚪ NIT apps/cli/src/commands/experimental/stack/restart/restart.integration.test.ts:177 test-coverage claude The restart handler suite lacks direct coverage for conflicting target flags, legacy output-flag rejection, and an inspectStack failure on the ID-target path.
Refuted findings (kept for transparency, not posted as review comments)
  • apps/cli/src/commands/experimental/stack/restart/restart.handler.ts:149 (consistency): Clearing the successful restart task instead of completing it is inconsistent with stack lifecycle output conventions.
    Refuted: The surrounding stack commands establish both output patterns: stop.handler.ts:141 and 181 and destroy.handler.ts:131 clear their tasks before emitting dedicated text results. Restart likewise immediately renders a full status block, so clearing avoids a redundant completion line and is consistent with those siblings.
  • apps/cli/docs/stack-commands.md:155 (documentation): The restart documentation is placed under an unrelated "Service selection and shutdown" heading.
    Refuted: The paragraph explicitly explains selecting a stack, stopping it, starting it again, and how service-selection flags are handled. Those subjects directly match the section's "Service selection and shutdown" heading.

Stats

Claude findings: 6 · Codex findings: 1 · Confirmed: 4 · Refuted: 2 · Uncertain: 0


Models: claude-opus-5 + gpt-5.6-sol · Trigger: auto · Workflow run

This review runs once per PR. A maintainer can request another with a /ai-review comment.

Comment thread apps/cli/src/commands/experimental/stack/restart/restart.handler.ts Outdated
Comment thread apps/cli/src/commands/experimental/stack/restart/restart.handler.ts
Comment thread apps/cli/src/commands/experimental/stack/restart/restart.command.ts Outdated
@jgoux
jgoux added this pull request to the merge queue Sep 14, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 14, 2026
@jgoux
jgoux added this pull request to the merge queue Sep 14, 2026
Merged via the queue into develop with commit c3e74aa Sep 14, 2026
29 checks passed
@jgoux
jgoux deleted the feat/stack-restart branch September 14, 2026 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants