Skip to content
quarry View Ticket
Login

View Ticket

api: landing write plane — open, comment, accept, reject

Closeda4a9f1879984e667eac7756af9681cd69c8b59e4Created 99.4 days agoUpdated 67.9 days ago
Description2026-08-23 12:23:15
Kind=Command, Auth=Token, alongside wiki.save and ticket.new/ticket.set: landing.open, landing.comment, landing.accept, landing.reject. Each mints ordinary zit artifacts — a forum post or a branch tag — so nothing here is quarry-private state. accept performs the merge and the tag transition together or neither. The sync fronter's push guard applies as it does to the existing command surface.
2026-08-23 18:36:26

Two corrections after reading zit#127 and src/cmd/landing.zig.

1. "together or neither" contradicts zit's contract. zit does the opposite, deliberately:

THE ORDER IS THE CONTRACT. Merge and commit run first; the outcome tag and the transition reply follow. A failure after the merge leaves merged work under a still-open landing, which one command settles. The reverse order would leave an accepted record over an unmerged branch — a lie in the permanent record.

The failure modes are asymmetric: recoverable noise on one side, a false statement in an append-only log on the other. quarry must follow the same order, not invent atomicity. This ticket's wording should say so.

2. accept is blocked upstream; the other three ops are not. landing.open, landing.comment and landing.reject mint forum artifacts only, and forum already appends to a bare store under -R. Build those now.

landing.accept cannot be served: zit landing accept refuses -R, requires the checkout to be ON the target branch, and leaves a dirty tree on conflict. Filed as danmestas/zit#131 asking for a bare-store accept that refuses cleanly instead of conflicting. Until it lands, the UI should say accept happens from a checkout rather than offering a button that cannot work.

Also unresolved and ours to decide: who may accept. zit#127 scoped approvals out ("Not asking for: approvals/required-reviewers"), which is right for a CLI where the operator is the authority. A multi-account forge is a different question, and RFC 0004 caps plus the caps-in-context seam make it answerable now.

2026-08-23 21:50:49

Shipped: landing.open, landing.comment, landing.reject, landing.accept.

Each mints ordinary zit artifacts through the zit landing verbs rather than hand-writing thread bodies — zit's module doc is explicit that the interface hides the encoding, and two encoders of one format is how the forge and the store come to disagree about what a record says.

Capabilities, as decided: accept takes i (it writes a merge check-in), the other three take 3 (they speak in the record's thread). No rule against accepting your own landing — inside a cathedral the author holds the commit bit, and fossil has no letter for a required second reviewer.

This ticket's original wording said accept performs the merge and the tag "together or neither". That was wrong and is not what shipped: zit's contract is ORDERED — merge and commit first, then the outcome tag and the transition reply — because a failure after the merge leaves merged work under an open landing, which one command settles, where the reverse leaves an accepted record over an unmerged branch: a lie in a log that cannot retract one.

Proven end to end in internal/harness/landing_flow_test.go against a real store: open, read the record back as an ordinary forum thread, comment, reject, refuse to re-settle it, then open a second one and ACCEPT it — merging to trunk through zit#131's bare-store path, which is the half that could not run at all until this week.