Land the project access and lifecycle role and work-state work on Backend main #234

Merged
weichen merged 13 commits from feature/project-access-lifecycle-u3-backend-merge into main 2026-10-21 04:06:34 +00:00
Owner

Why: the project access and lifecycle units (U1 role narrowing to a single project-access boolean, U2 creator authority, U3 member history, U4 project work states) were implemented and pushed on feature/project-access-lifecycle-u3-backend but never landed here, so Dev's pinned Backend did not contain them. This merges that line into Backend main.

Evidence:

  • The merge is conflict-free against current origin/main; no manual conflict resolution was needed.
  • GOWORK=off go vet ./... && GOWORK=off go test -count=1 ./... green on the merge commit (SELF, go vet VET_OK, no FAIL lines).
  • Before this merge the tree was red: TestConversationWorkErrorCategorization failed at the delivery branch's own tip bd640df, not because of the merge. origin/main passed the same case.
  • Root cause of that red: the U3 change switched listConversations from the work gate to the read gate (s.projectWork → s.projectRead, an intentional semantic change so a removed member keeps read access to their own sessions) but also switched the error writer from writeWorkFailure(w, extension.WorkOperationConversation, err) to writeProjectErr(w, err). writeProjectErr writes err.Error() directly, and extension.WorkFailure.Error() renders as "<operation>: <reason>" with an empty operation here, so GET /api/projects/{id}/conversations degraded to the malformed body ": mapping-not-ready\n" — status code preserved, operation label lost.
  • Fix: keep s.projectRead, restore writeWorkFailure(w, extension.WorkOperationConversation, err). writeWorkFailure categorizes and re-adds the operation label, and falls through to writeProjectErr for errors that are not work failures, so the non-member 404 behaviour is preserved unchanged.
  • No test file was modified and no assertion was weakened; the existing main-line assertions pass as written.

Impact: Backend only. The RDM half of the same delivery lands separately. Dev advances its modules/backend gitlink only after this merges.

Refs: Dev PR #634.

Why: the project access and lifecycle units (U1 role narrowing to a single project-access boolean, U2 creator authority, U3 member history, U4 project work states) were implemented and pushed on `feature/project-access-lifecycle-u3-backend` but never landed here, so Dev's pinned Backend did not contain them. This merges that line into Backend main. Evidence: - The merge is conflict-free against current `origin/main`; no manual conflict resolution was needed. - `GOWORK=off go vet ./... && GOWORK=off go test -count=1 ./...` green on the merge commit (SELF, `go vet` VET_OK, no FAIL lines). - Before this merge the tree was **red**: `TestConversationWorkErrorCategorization` failed at the delivery branch's own tip `bd640df`, not because of the merge. `origin/main` passed the same case. - Root cause of that red: the U3 change switched `listConversations` from the work gate to the read gate (`s.projectWork` → `s.projectRead`, an intentional semantic change so a removed member keeps read access to their own sessions) but also switched the error writer from `writeWorkFailure(w, extension.WorkOperationConversation, err)` to `writeProjectErr(w, err)`. `writeProjectErr` writes `err.Error()` directly, and `extension.WorkFailure.Error()` renders as `"<operation>: <reason>"` with an empty operation here, so `GET /api/projects/{id}/conversations` degraded to the malformed body `": mapping-not-ready\n"` — status code preserved, operation label lost. - Fix: keep `s.projectRead`, restore `writeWorkFailure(w, extension.WorkOperationConversation, err)`. `writeWorkFailure` categorizes and re-adds the operation label, and falls through to `writeProjectErr` for errors that are not work failures, so the non-member 404 behaviour is preserved unchanged. - No test file was modified and no assertion was weakened; the existing main-line assertions pass as written. Impact: Backend only. The RDM half of the same delivery lands separately. Dev advances its `modules/backend` gitlink only after this merges. Refs: Dev PR #634.
weichen added 13 commits 2026-10-21 03:55:43 +00:00
Why: the cursor account hit its monthly usage limit (resets 2026-11-10);
attempts fail before useful work. Routing falls through to antigravity and
pi per the existing candidate order; re-enable when the quota resets.
Reason recorded on the U3 task card.

Impact: AGENT-EXECUTION.md only (rides the U3 PR, auditable).

Refs: plan 2026-10-19-1440 U3.
Why: the Gemini endpoint behind agy dropped the final streaming response
with EOF in three consecutive attempts, each after ~30 minutes of completed
work; routing falls through to pi. Re-enable when the endpoint recovers.
Reason recorded on the U3 task card.

Impact: AGENT-EXECUTION.md only.

Refs: plan 2026-10-19-1440 U3.
Why: compose the lifecycle line (role narrowing to a single project-access
boolean, U3b member-history read path) with Backend main (capability
association, explanation, super-admin). Per plan 2026-10-19-1440 R2/KTD2
the narrowed single-boolean write model supersedes the linked-cap expansion
and its association invariant; main non-conflicting work (explanation,
super-admin, tavily, O2 pins) is incorporated.

Impact: integration merge on the lifecycle branch; suites arbitrate.
Why: the project access and lifecycle units (U1 role narrowing to a single
project-access boolean, U2 creator authority, U3 member history, U4 project
work states) were implemented and pushed on this line but never landed on
Backend main, so Dev's pinned Backend does not contain them.

Evidence: merge is conflict-free against current origin/main; full
vet-and-test runs on the merge commit.

Impact: Backend only. RDM side is delivered separately.

Refs: Dev PR #634.
agent-exec transport 39075300fab9c8ac1d78ca2dd93074fd/55144c34e7ce
governance / governance (pull_request) Successful in 15s
ci / vet-and-test (pull_request) Successful in 1m36s
284d3ac781
weichen merged commit 7158bead16 into main 2026-10-21 04:06:34 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: weichen/Agent-System-Backend#234