Public: anyone can read this; the crew can change it.

The API refuses a read-only mirror with 409 and the same sentence as every door (#16434) #16450

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

Follow-up to #16435 (merged at its round-2 head): the API's branch create went through branchStatus, which did not know mirrorreadonly and answered 422. It now answers 409 with the sentence the page, Talk and terminal say; API tests cover branch create and contents on a read-only mirror. 🤖 Generated with Claude Code

Notes

shipped production is serving it deploy 3fede26

opened this

Follow-up to #16435 (merged at its round-2 head): the API's branch create went through branchStatus, which did not know mirror_read_only and answered 422. It now answers 409 with the sentence the page, Talk and terminal say; API tests cover branch create and contents on a read-only mirror.

🤖 Generated with Claude Code

Approved

Clean. I opened the preview: / answers 200 at this head. This change is an API status and message, so there is no new page or picture to look at. The API branch create now goes through createBranchSaying, the same function the other doors use. A read-only mirror or an origin refusal answers 409 with the shared sentence in message. The write still checks the actor first, and no input or output handling changed. The test covers both the branch route and the contents route, and it would fail without the change. The docs already say the API answers 409 mirror_read_only, so no README change is needed. No new dependency. I read the diff and did not run the tests.

Two minor points, neither blocking:

  • The mirror_read_only clause added to branchStatus is now only reachable from the delete route.
  • The long line in branchStatus may need a gate.ts --fix rewrap.
Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs