Skip to content

πŸ› fix(api): explicit 501 for agent containers without controller lifecycle transport - #663

Merged
scttbnsn merged 1 commit into
dev/v1.6from
fix/v1.6-edge-lifecycle-501-637
Aug 4, 2026
Merged

πŸ› fix(api): explicit 501 for agent containers without controller lifecycle transport#663
scttbnsn merged 1 commit into
dev/v1.6from
fix/v1.6-edge-lifecycle-501-637

Conversation

@scttbnsn

@scttbnsn scttbnsn commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Refs #637 (closed by #651's native-transport half in rc.11 β€” this is the remaining explicit-error half, matching #650's unresolved review concern).

Start/stop/restart and backup rollback returned a bare 404 NO_DOCKER_TRIGGER_FOUND_ERROR for agent-owned containers whose agent doesn't advertise usesControllerDockerTransport β€” indistinguishable from container-not-found. Worse, a legacy AgentTrigger without transport could still be found and then throw in getWatcher(), producing a 500.

  • New AgentClient.hasControllerDockerTransport(watcherName) + isAgentLifecycleUnsupported(container): the 501 decision keys on the agent's actual capability, not trigger absence (Codex review caught the found-then-throw 500 path and the transient-miss mislabel).
  • Agent known + no transport β†’ 501 AGENT_LIFECYCLE_UNSUPPORTED_ERROR (in container-actions.ts AND backup.ts rollback β€” the adversarial round caught rollback had the identical defect).
  • Agent known + capable + trigger transiently missing β†’ existing 404 unchanged. Non-agent containers β†’ unchanged.
  • OpenAPI 501 entries added for all four routes.

Review provenance: adversarial verify round (2 findings, repaired), independent Codex review (1 finding, repaired), re-verified approve, full app suite green.

@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
drydock-website Ready Ready Preview Aug 4, 2026 8:58pm
drydockdemo-website Ready Ready Preview Aug 4, 2026 8:58pm

@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@scttbnsn, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 5 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
βš™οΈ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 82185c48-ff4d-4baa-8b34-c198600d2aae

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between c4cd8e0 and 0fbc3f1.

β›” Files ignored due to path filters (1)
  • CHANGELOG.md is excluded by !CHANGELOG.md
πŸ“’ Files selected for processing (9)
  • app/agent/AgentClient.test.ts
  • app/agent/AgentClient.ts
  • app/api/backup.test.ts
  • app/api/backup.ts
  • app/api/container-actions.test.ts
  • app/api/container-actions.ts
  • app/api/docker-trigger.ts
  • app/api/openapi/paths/containers.test.ts
  • app/api/openapi/paths/containers.ts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❀️ Share

Comment @coderabbitai help to get the list of available commands.

…e transport

executeAction (POST /:id/start|stop|restart) returned a bare 404
NO_DOCKER_TRIGGER_FOUND_ERROR whenever the docker-trigger lookup missed,
indistinguishable from "container not found" β€” for agents that don't
advertise usesControllerDockerTransport this was the only signal surfaced
to the UI. Agent-owned containers now get a 501 naming the missing
capability; non-agent containers keep the existing 404. OpenAPI specs for
start/stop/restart document the new 501 response.

Fixes: #637
@scttbnsn
scttbnsn force-pushed the fix/v1.6-edge-lifecycle-501-637 branch from 4f1079e to 0fbc3f1 Compare August 4, 2026 21:46
@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

Deployment failed with the following error:

Resource is limited - try again in 24 hours (more than 100, code: "api-deployments-free-per-day").

Learn More: https://vercel.com/codeswhat?upgradeToPro=build-rate-limit

@scttbnsn
scttbnsn merged commit 944143f into dev/v1.6 Aug 4, 2026
23 of 25 checks passed
@scttbnsn
scttbnsn deleted the fix/v1.6-edge-lifecycle-501-637 branch August 4, 2026 22:10
scttbnsn added a commit that referenced this pull request Aug 5, 2026
Wholesale-tree sync ahead of the v1.6.0-rc.12 cut: the head commit's
tree is `origin/dev/v1.6`'s tree verbatim (`630c64ec`), parented on
main's current head (`67f23419`). Squash-merging makes main
tree-identical to `dev/v1.6`, satisfying the release-cut drift guard
(`git diff --quiet origin/main origin/dev/v1.6`).

Brings in since rc.11: #659 security pins, #662/#660/#661/#663 runtime
fixes (#636/#604/#605/#637), #664 guard floor, #653–#656 deps, #665
Crowdin, #666 rc.12 prep.

After merge: dispatch `release-cut.yml --ref main -f
release_tag=v1.6.0-rc.12`.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Changelog

- πŸ”’ Updated dependency security pins and security-version tests.
- ✨ Added anonymous-authenticated WebSocket log streams with IP-based
rate limits.
- ✨ Added agent component-registration state tracking.
- πŸ”§ Downgraded selected update blockers during agent registration.
- πŸ”§ Added controller-Docker transport detection.
- πŸ› Added HTTP `501` responses for unsupported agent lifecycle actions.
- πŸ› Fixed maturity filtering to use per-container thresholds.
- πŸ› Changed Docker publish-date lookup failures to warning logs.
- πŸ”§ Updated dependency versions, release metadata, documentation, mocks,
and changelog links from `v1.6.0-rc.11` to `v1.6.0-rc.12`.
- ✨ Added release highlights for `v1.6.0-rc.12`.

## Concerns

- Fix the French `containerLogs.stderr` value if `"sdterr"` is not
intentional.
- Verify the release date `August 4, 2026`.
- Dispatch the release-cut workflow for `main` with
`release_tag=v1.6.0-rc.12` after merging.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
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.

3 participants