Skip to content

CLI: stop and delete should error on not found containers#878

Merged
dcantah merged 1 commit intoapple:mainfrom
dcantah:change-stop-and-kill-behavior
Mar 25, 2026
Merged

CLI: stop and delete should error on not found containers#878
dcantah merged 1 commit intoapple:mainfrom
dcantah:change-stop-and-kill-behavior

Conversation

@dcantah
Copy link
Copy Markdown
Member

@dcantah dcantah commented Nov 14, 2025

Same as we'd done with kill.

➜  container git:(stop-kill-throw-error) ✗ ./bin/container stop foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to stop container" (cause: "notFound: "container with ID baz not found"")
internalError: "failed to stop container" (cause: "notFound: "container with ID bar not found"")
internalError: "failed to stop container" (cause: "notFound: "container with ID foo not found"")
➜  container git:(stop-kill-throw-error) ✗ ./bin/container kill foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to kill container" (cause: "notFound: "container with ID foo not found"")
internalError: "failed to kill container" (cause: "notFound: "container with ID bar not found"")
internalError: "failed to kill container" (cause: "notFound: "container with ID baz not found"")
➜  container git:(stop-kill-throw-error) ✗ ./bin/container delete foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to delete container" (cause: "notFound: "container with ID foo not found"")
internalError: "failed to delete container" (cause: "notFound: "container with ID baz not found"")
internalError: "failed to delete container" (cause: "notFound: "container with ID bar not found"")

@dcantah dcantah force-pushed the change-stop-and-kill-behavior branch from cd90009 to ace9702 Compare November 14, 2025 01:26
@dcantah dcantah marked this pull request as ready for review November 14, 2025 04:43
Comment thread Sources/ContainerCommands/Container/ContainerKill.swift Outdated
Comment thread Sources/ContainerCommands/Container/ContainerKill.swift Outdated
Comment thread Sources/ContainerCommands/Container/ContainerStop.swift Outdated
Comment thread Sources/ContainerCommands/Container/ContainerStop.swift Outdated
Comment thread Sources/ContainerCommands/Container/ContainerKill.swift Outdated
Comment thread Sources/ContainerCommands/Container/ProcessUtils.swift Outdated
Same as we'd done with kill.

➜  container git:(stop-kill-throw-error) ✗ ./bin/container stop foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to stop container" (cause: "notFound: "container with ID baz not found"")
internalError: "failed to stop container" (cause: "notFound: "container with ID bar not found"")
internalError: "failed to stop container" (cause: "notFound: "container with ID foo not found"")
➜  container git:(stop-kill-throw-error) ✗ ./bin/container kill foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to kill container" (cause: "notFound: "container with ID foo not found"")
internalError: "failed to kill container" (cause: "notFound: "container with ID bar not found"")
internalError: "failed to kill container" (cause: "notFound: "container with ID baz not found"")
➜  container git:(stop-kill-throw-error) ✗ ./bin/container delete foo bar baz
Warning! Running debug build. Performance may be degraded.
Error: internalError: "failed to delete container" (cause: "notFound: "container with ID foo not found"")
internalError: "failed to delete container" (cause: "notFound: "container with ID baz not found"")
internalError: "failed to delete container" (cause: "notFound: "container with ID bar not found"")
@dcantah dcantah force-pushed the change-stop-and-kill-behavior branch from 3a6aefe to ca16820 Compare March 25, 2026 10:58
@dcantah dcantah changed the title CLI: stop and kill should error on not found containers CLI: stop and delete should error on not found containers Mar 25, 2026
Comment thread Sources/ContainerCommands/Container/ContainerStop.swift
@dcantah dcantah merged commit 31c866a into apple:main Mar 25, 2026
3 checks passed
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