redeploy-services — every Grist ORG-access write is refused 403 on the box, so #1535's everyone→editor seed and #1537's operator→owner grant both never land: the health check dies 36/36 and data-collections reads "not yet applied" forever #1575

Closed
opened 2026-09-18 08:30:28 +00:00 by matou-build-agent · 3 comments

The failure

Drive 20260918T074206Z (sig 03347fc9985d, commit 357813df) red at redeploy-services, 29/30 legs green:

role posture not honest on 1 door(s) — proof-operator's role on data-collections
reads "not yet applied" (org owner) — the reconcile is still owed

Thrown at app/tests/e2e/journey.rented-services.spec.ts:628. The assertion is honest and is catching a real product defect — nothing in the harness is wrong.

The decisive new evidence: the access-list snapshot

#1574 (commit 357813df) added the access-list snapshot to a refused org-access write. This drive is the first to carry it, and it disproves that commit's hypothesis.

logs/droplet-journal.txt:1845–1971 — data-collections failed all 36 warm-up attempts of the redeploy (08:18:12 → 08:24:05), every one identical:

service=data-collections attempt=36 attempts=36 verdict=failed
error="grist: could not set the community team site's default access (the operator an
owner, every member an editor) (HTTP 403) — the register is not serving —
access list at the refusal: operator=owners idss-health-nonowner@data-collections.local=guests"

Read that list carefully. It holds exactly two principals:

  • operator=owners — Grist's own bootstrap of the single org from GRIST_DEFAULT_EMAIL (internal/clan/datacollections.go:370), not something we wrote.
  • idss-health-nonowner@data-collections.local=guests — the health fixture's doc-level grant (PATCH /api/docs/<id>/access, datacollectionshealth.go:498-504, identity at internal/clan/datacollections.go:140). Grist surfaces a doc-guest in the org list as guests.

Absent from it: everyone@getgrist.com (the #1535 seed) and proof-operator (the #1537 grant). Both of those are org-level writes.

So: doc-level access writes land; org-level access writes are refused 403. No PATCH /api/orgs/data-collections/access has ever succeeded on this box.

Why #1574's fix could not have helped

dataCollectionsEnsureOrgAccess (control-plane/cmd/control-plane/datacollectionshealth.go:254-284) now reads first and PATCHes only the genuinely-missing entries. But everyone@getgrist.com is never in the read-back (it is not in the snapshot), so dataCollectionsOrgRoleOf(access, everyone) is "" on every single run, the delta is never empty, the PATCH always fires, and it always 403s. The read-first seed is a genuine improvement and should stay; it just was not the fault.

It went green in tests because the double does not model the box. gristFake.patchOrgAccess / writeOrgAccess (control-plane/cmd/control-plane/provision_datacollections_health_test.go:236-283) accept any org-access PATCH and echo everyone@getgrist.com straight back out of the GET. Real Grist does neither. Whatever fix lands must move that double onto the box's observed behaviour first, or the next drive reds the same way.

Defect 1 (the red's root): Grist refuses org-level access writes

The same 403 hits both writers on the same endpoint:

  • the health seed (datacollectionshealth.go:271-279) — data-collections never reaches healthy;
  • the roles reconciler setRole (internal/datacollectionssvc/datacollectionssvc.go:241-248) — proof-operator → owners never lands, which is why they are missing from the snapshot at 08:24:05.

Corroborating: setRole gained three Info log lines in #1574 (datacollectionssvc.go:228, :239, :250). None of the three appears anywhere in the journal (105 control-plane lines harvested, no -n truncation) — the port ran and returned on its error path, the only path that logs nothing. That is consistent with a refused PATCH, and is the direct cause of data-collections landing in RoleReconcile.Outstanding at grant time (internal/member/roles.go:259-261, folded at :271) and surfacing as not_applied on the member detail (internal/member/detail.go:399).

Artifact trail across the two reads:

  • artifacts/roles/detail-proof-operator-granted.json — surveys and data-collections both not_applied: true.
  • artifacts/roles/detail-proof-operator-after-redeploy.json — newsletters applied (Super Admin), surveys cleared, data-collections still not_applied: true.

Suspected layer — needs a ruling

The render (internal/clan/datacollections.go:350-384) sets GRIST_SINGLE_ORG, GRIST_IN_SERVICE, GRIST_FORWARD_AUTH_HEADER, GRIST_DEFAULT_EMAIL, GRIST_SANDBOX_FLAVOR — and no product/seat env. grist-core assigns a team site created this way a default product whose features deny adding users, and updateOrgPermissions then refuses the write; GRIST_DEFAULT_PRODUCT is the usual lever. That is a hypothesis, not a verified fact — it must be confirmed against live Grist 1.7.18 (the pinned image, journal line 517) by reading the 403's response body, which neither writer currently captures.

Why this needs Ben, not a swarm worker acting alone. Both candidate repairs are product-surface, one-way-ish decisions about what a community's Grist means:

  1. Give the team site a product/seat posture — a new GRIST_DEFAULT_PRODUCT in the render. This changes what a deploy does and what the community's data-collections site is, on every existing and future community.
  2. Move #1535's posture off org-level access entirely — seed and reconcile at the workspace/doc level instead (the level the evidence shows does accept writes). This re-opens Ben's #1535 ruling ('one community sign-in, every door; an operator is admin everywhere') for Grist specifically, because workspace-level access is not the same promise as org owner.

A third option — capture the 403 body first and re-drive to learn the real reason before choosing — is cheap and may be the right first move.

Defect 2 (stacked): the deploy-time reconcile can never clear the tail for a per-person port

This one reds the leg even after Grist is fixed, so it must be fixed in the same arc.

ReconcileService (internal/member/roles.go:298-338) has two paths:

  • AppliesAtDeploy ports (surveys) → clearRoleTail(service) (:323-324). This is why surveys cleared between the two artifacts above. It works.
  • per-person HTTP ports (data-collections, document-archive) → _ = o.catalogue.ReconcileRole(service, m.PersonID, true) (:335). The result is discarded and the role tail is never touched.

So once a per-person port lands in RoleReconcile.Outstanding via a failed ReconcileRoles, only another full ReconcileRoles (grant/revoke/member-add) can clear it — a deploy never can, no matter how successfully the per-person verb reconciles. The redeploy-services leg's premise (spec comment at journey.rented-services.spec.ts:557-562: 'a P4 add of one more service so #1537's deploy-time reconcile runs for an operator that already exists') is therefore only true for AppliesAtDeploy ports today.

The fix shape is small but is a judgement call: should ReconcileService clear the service from the member's tail on a successful per-person ReconcileRole, and add it on failure? That is a decision about what 'outstanding' promises on the member detail — a trust-moment surface — so it wants the same ruling.

Why I refused to heal

Refusal rule 3 (product-behaviour surface as a design decision). Defect 1's repair is a new deploy default (GRIST_DEFAULT_PRODUCT) or a re-shaping of #1535's access posture for Grist — a one-way door about what a deploy does and what a community sees. Defect 2's repair changes what the member-detail tail promises. Neither is a mechanical repair that merely makes the code do what it already meant, so the fast lane does not apply.

I also cannot test either fix here: there is no live Grist on this workstation, and the only in-repo Grist is the gristFake double that is itself wrong about the box (it accepts the very writes Grist refuses). A green go test ./control-plane/... here would prove nothing — that is precisely the trap #1574 fell into.

Finally, the healer history for sig 03347fc9985d shows two prior in-lane heals (2864527a journal harvest, 9ad4cd80 Services-tab nav) that each repaired how this fault presented and left it red. This signature has resisted a heal twice; it is swarm/ruling work.

Re-drive note

The drive's box is released; the live leg needs a rented droplet and re-proves on the next drive. Both defects must land together — fixing Grist's 403 alone still leaves data-collections named in the tail (defect 2), and fixing the tail alone leaves the operator genuinely not an owner in Grist (defect 1).

drive 20260918T074206Z red at redeploy-services: role posture not honest on 1 door(s) — proof-operator's role on data-collections reads "not yet applied" (org owner) — the reconcile is still owed
evidence: /home/dev/swarm/Matou/idss/test-results/drive-rented-services/20260918T074206Z on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured

## The failure Drive `20260918T074206Z` (sig `03347fc9985d`, commit `357813df`) red at `redeploy-services`, 29/30 legs green: ``` role posture not honest on 1 door(s) — proof-operator's role on data-collections reads "not yet applied" (org owner) — the reconcile is still owed ``` Thrown at `app/tests/e2e/journey.rented-services.spec.ts:628`. The assertion is honest and is catching a real product defect — nothing in the harness is wrong. ## The decisive new evidence: the access-list snapshot #1574 (commit `357813df`) added the access-list snapshot to a refused org-access write. This drive is the first to carry it, and it **disproves that commit's hypothesis**. `logs/droplet-journal.txt:1845–1971` — data-collections failed **all 36** warm-up attempts of the redeploy (08:18:12 → 08:24:05), every one identical: ``` service=data-collections attempt=36 attempts=36 verdict=failed error="grist: could not set the community team site's default access (the operator an owner, every member an editor) (HTTP 403) — the register is not serving — access list at the refusal: operator=owners idss-health-nonowner@data-collections.local=guests" ``` Read that list carefully. It holds exactly two principals: - `operator=owners` — **Grist's own bootstrap** of the single org from `GRIST_DEFAULT_EMAIL` (`internal/clan/datacollections.go:370`), not something we wrote. - `idss-health-nonowner@data-collections.local=guests` — the health fixture's **doc-level** grant (`PATCH /api/docs/<id>/access`, `datacollectionshealth.go:498-504`, identity at `internal/clan/datacollections.go:140`). Grist surfaces a doc-guest in the org list as `guests`. Absent from it: `everyone@getgrist.com` (the #1535 seed) **and** `proof-operator` (the #1537 grant). Both of those are **org**-level writes. **So: doc-level access writes land; org-level access writes are refused 403. No `PATCH /api/orgs/data-collections/access` has ever succeeded on this box.** ## Why #1574's fix could not have helped `dataCollectionsEnsureOrgAccess` (`control-plane/cmd/control-plane/datacollectionshealth.go:254-284`) now reads first and PATCHes only the genuinely-missing entries. But `everyone@getgrist.com` is **never** in the read-back (it is not in the snapshot), so `dataCollectionsOrgRoleOf(access, everyone)` is `""` on every single run, the delta is **never** empty, the PATCH always fires, and it always 403s. The read-first seed is a genuine improvement and should stay; it just was not the fault. It went green in tests because the double does not model the box. `gristFake.patchOrgAccess` / `writeOrgAccess` (`control-plane/cmd/control-plane/provision_datacollections_health_test.go:236-283`) accept any org-access PATCH and echo `everyone@getgrist.com` straight back out of the GET. Real Grist does neither. **Whatever fix lands must move that double onto the box's observed behaviour first, or the next drive reds the same way.** ## Defect 1 (the red's root): Grist refuses org-level access writes The same 403 hits both writers on the same endpoint: - the health seed (`datacollectionshealth.go:271-279`) — data-collections never reaches healthy; - the roles reconciler `setRole` (`internal/datacollectionssvc/datacollectionssvc.go:241-248`) — `proof-operator` → `owners` never lands, which is why they are missing from the snapshot at 08:24:05. Corroborating: `setRole` gained three Info log lines in #1574 (`datacollectionssvc.go:228`, `:239`, `:250`). **None of the three appears anywhere in the journal** (105 control-plane lines harvested, no `-n` truncation) — the port ran and returned on its *error* path, the only path that logs nothing. That is consistent with a refused PATCH, and is the direct cause of `data-collections` landing in `RoleReconcile.Outstanding` at grant time (`internal/member/roles.go:259-261`, folded at `:271`) and surfacing as `not_applied` on the member detail (`internal/member/detail.go:399`). Artifact trail across the two reads: - `artifacts/roles/detail-proof-operator-granted.json` — `surveys` and `data-collections` both `not_applied: true`. - `artifacts/roles/detail-proof-operator-after-redeploy.json` — `newsletters` applied (Super Admin), `surveys` cleared, **`data-collections` still `not_applied: true`**. ### Suspected layer — needs a ruling The render (`internal/clan/datacollections.go:350-384`) sets `GRIST_SINGLE_ORG`, `GRIST_IN_SERVICE`, `GRIST_FORWARD_AUTH_HEADER`, `GRIST_DEFAULT_EMAIL`, `GRIST_SANDBOX_FLAVOR` — and **no product/seat env**. grist-core assigns a team site created this way a default product whose features deny adding users, and `updateOrgPermissions` then refuses the write; `GRIST_DEFAULT_PRODUCT` is the usual lever. That is a hypothesis, not a verified fact — it must be confirmed against live Grist 1.7.18 (the pinned image, journal line 517) by reading the 403's response body, which neither writer currently captures. **Why this needs Ben, not a swarm worker acting alone.** Both candidate repairs are product-surface, one-way-ish decisions about what a community's Grist means: 1. **Give the team site a product/seat posture** — a new `GRIST_DEFAULT_PRODUCT` in the render. This changes what a deploy does and what the community's data-collections site *is*, on every existing and future community. 2. **Move #1535's posture off org-level access entirely** — seed and reconcile at the workspace/doc level instead (the level the evidence shows *does* accept writes). This re-opens Ben's #1535 ruling ('one community sign-in, every door; an operator is admin everywhere') for Grist specifically, because workspace-level access is not the same promise as org owner. A third option — capture the 403 body first and re-drive to learn the real reason before choosing — is cheap and may be the right first move. ## Defect 2 (stacked): the deploy-time reconcile can never clear the tail for a per-person port This one reds the leg **even after Grist is fixed**, so it must be fixed in the same arc. `ReconcileService` (`internal/member/roles.go:298-338`) has two paths: - `AppliesAtDeploy` ports (surveys) → `clearRoleTail(service)` (`:323-324`). This is why `surveys` cleared between the two artifacts above. It works. - per-person HTTP ports (data-collections, document-archive) → `_ = o.catalogue.ReconcileRole(service, m.PersonID, true)` (`:335`). **The result is discarded and the role tail is never touched.** So once a per-person port lands in `RoleReconcile.Outstanding` via a failed `ReconcileRoles`, only another full `ReconcileRoles` (grant/revoke/member-add) can clear it — a deploy never can, no matter how successfully the per-person verb reconciles. The `redeploy-services` leg's premise (spec comment at `journey.rented-services.spec.ts:557-562`: 'a P4 add of one more service so #1537's deploy-time reconcile runs for an operator that already exists') is therefore only true for `AppliesAtDeploy` ports today. The fix shape is small but is a judgement call: should `ReconcileService` clear the service from the member's tail on a successful per-person `ReconcileRole`, and add it on failure? That is a decision about what 'outstanding' promises on the member detail — a trust-moment surface — so it wants the same ruling. ## Why I refused to heal **Refusal rule 3 (product-behaviour surface as a design decision).** Defect 1's repair is a new deploy default (`GRIST_DEFAULT_PRODUCT`) or a re-shaping of #1535's access posture for Grist — a one-way door about what a deploy does and what a community sees. Defect 2's repair changes what the member-detail tail promises. Neither is a mechanical repair that merely makes the code do what it already meant, so the fast lane does not apply. I also **cannot test either fix here**: there is no live Grist on this workstation, and the only in-repo Grist is the `gristFake` double that is itself wrong about the box (it accepts the very writes Grist refuses). A green `go test ./control-plane/...` here would prove nothing — that is precisely the trap #1574 fell into. Finally, the healer history for sig `03347fc9985d` shows two prior in-lane heals (`2864527a` journal harvest, `9ad4cd80` Services-tab nav) that each repaired how this fault *presented* and left it red. This signature has resisted a heal twice; it is swarm/ruling work. ## Re-drive note The drive's box is released; the live leg needs a rented droplet and re-proves on the next drive. Both defects must land together — fixing Grist's 403 alone still leaves `data-collections` named in the tail (defect 2), and fixing the tail alone leaves the operator genuinely not an owner in Grist (defect 1). drive `20260918T074206Z` red at `redeploy-services`: `role posture not honest on 1 door(s) — proof-operator's role on data-collections reads "not yet applied" (org owner) — the reconcile is still owed` evidence: `/home/dev/swarm/Matou/idss/test-results/drive-rented-services/20260918T074206Z` on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured <!-- rehearsal-sig: 03347fc9985d -->
Author
Member

Session-runner report (ADR 0174) — the two-way half landed; the product-surface repair routes to Ben.

Landed on main in f541461c (pushed; git build/vet/gofmt + full go test ./... green — golangci-lint not run, it lives in nix develop .#go-ci and is unavailable on this host):

1. The diagnostic #1574 lacked (both org-access writers now carry Grist's OWN 403 body). The ticket's decisive finding — the #1574 access-list snapshot shows doc-level writes land and all org-level writes are refused — is correct, but why the box 403s is still unknown because neither writer captured Grist's response body. Now:

  • dataCollectionsDo (control-plane/cmd/control-plane/datacollectionshealth.go) read the body then threw it away; its refusal error now carries it ( — Grist said: <body>). This is the writer whose failure the drive journals 36/36.
  • setRole/request (internal/datacollectionssvc/datacollectionssvc.go) returned a bare HTTP 403 and logged nothing on the error path — "the only path that logs nothing", exactly as the ticket notes. It now both surfaces the body in the error AND logs it (the fourth setRole log line #1574 never had).

Proof: TestDataCollectionsHealth_OrgAccessFailureCarriesGristReason, TestDataCollectionsPort_RefusedWriteCarriesGristReason (error + log carry the body), against a double modelling the box's refusal — not the #1574 trap (the double 403s, it does not accept-and-echo).

2. Defect 2 (stacked) — the deploy-time reconcile can now clear a per-person port's tail. ReconcileService's per-person HTTP branch discarded ReconcileRole's result and never touched the tail (internal/member/roles.go), so a per-person port (data-collections/document-archive) outstanding via a failed grant could ONLY be cleared by a later full ReconcileRoles — a deploy that healed the port left the member reading "not yet applied" forever. It now clears the service from a member's tail on a landed per-person reconcile and keeps it on a still-failing one (new setServiceOutstanding), the same honest footing the AppliesAtDeploy branch (#1554) already had.

Proof: TestReconcileService_PerPersonSuccessClearsOutstandingTail (red before, green after), …FailureKeepsOutstandingTail (the honest data-collections-still-403 guard).

Ruled by agent under ADR 0174 — veto anytime. Both are revertible, off no one-way-door line, and offline-provable at the seam. #1574's read-first seed stays (a genuine improvement); it was never the fault.


Why human

Defect 1 — WHY Grist 1.7.18 refuses every org-level access write — is a one-way-door ruling I cannot make or prove here.

  • Not provable on this host (ADR 0174 rule 1b fails). There is no live Grist on matou-workstation, and the only in-repo Grist is the double, which the ticket shows is wrong about the box (it accepts the writes Grist refuses). A green go test here would prove nothing — the #1574 trap. The real reason needs the next live re-drive (a rented droplet), which the diagnostic above now makes it capture. This is not a two-box live drive a one-shot session runs.
  • The repair is a one-way door either way. Two candidates, both product-surface:
    1. GRIST_DEFAULT_PRODUCT in the render (internal/clan/datacollections.go) — changes what a deploy does and what every community's data-collections site IS. A new deploy default.
    2. Move #1535's posture off org-level to workspace/doc level — the level the evidence shows does accept writes — which reopens your #1535 ruling ("one community sign-in, every door; an operator is admin everywhere / org owner"), because workspace access is a weaker promise than org owner.

Proposed default ruling (adopt whichever you prefer, or a third):

  • (A) Keep the org-owner posture and add GRIST_DEFAULT_PRODUCT (the "Free"/team product that permits user adds) to the render — smallest change, preserves the #1535 promise — pending confirmation from the next drive's captured 403 body that a default-product denial is in fact the cause.
  • (B) If the body shows the org simply cannot take org-level grants in this single-org config, re-shape #1535 for Grist to workspace/doc-level owner (the operator owns the community workspace, not the org).

You already own the whakatohea-demo Grist org, so you may be able to rule now without the re-drive.

Re-drive note: the leg only goes green once Defect 1's repair also lands — Defect 2 alone correctly leaves data-collections outstanding while it genuinely 403s. The drive's box is released; the live leg re-proves on the next drive.

Leaving ready-for-human for the Defect-1 ruling.

**Session-runner report (ADR 0174) — the two-way half landed; the product-surface repair routes to Ben.** Landed on `main` in `f541461c` (pushed; `git build`/vet/gofmt + full `go test ./...` green — golangci-lint not run, it lives in `nix develop .#go-ci` and is unavailable on this host): **1. The diagnostic #1574 lacked (both org-access writers now carry Grist's OWN 403 body).** The ticket's decisive finding — the #1574 access-list snapshot shows doc-level writes land and *all* org-level writes are refused — is correct, but *why* the box 403s is still unknown because neither writer captured Grist's response body. Now: - `dataCollectionsDo` (`control-plane/cmd/control-plane/datacollectionshealth.go`) read the body then threw it away; its refusal error now carries it (` — Grist said: <body>`). This is the writer whose failure the drive journals 36/36. - `setRole`/`request` (`internal/datacollectionssvc/datacollectionssvc.go`) returned a bare `HTTP 403` and logged nothing on the error path — "the only path that logs nothing", exactly as the ticket notes. It now both surfaces the body in the error AND logs it (the fourth `setRole` log line #1574 never had). Proof: `TestDataCollectionsHealth_OrgAccessFailureCarriesGristReason`, `TestDataCollectionsPort_RefusedWriteCarriesGristReason` (error + log carry the body), against a double modelling the box's refusal — not the #1574 trap (the double 403s, it does not accept-and-echo). **2. Defect 2 (stacked) — the deploy-time reconcile can now clear a per-person port's tail.** `ReconcileService`'s per-person HTTP branch discarded `ReconcileRole`'s result and never touched the tail (`internal/member/roles.go`), so a per-person port (data-collections/document-archive) outstanding via a failed grant could ONLY be cleared by a later full `ReconcileRoles` — a deploy that *healed* the port left the member reading "not yet applied" forever. It now clears the service from a member's tail on a landed per-person reconcile and keeps it on a still-failing one (new `setServiceOutstanding`), the same honest footing the `AppliesAtDeploy` branch (#1554) already had. Proof: `TestReconcileService_PerPersonSuccessClearsOutstandingTail` (red before, green after), `…FailureKeepsOutstandingTail` (the honest data-collections-still-403 guard). Ruled by agent under ADR 0174 — veto anytime. Both are revertible, off no one-way-door line, and offline-provable at the seam. #1574's read-first seed stays (a genuine improvement); it was never the fault. --- ## Why human **Defect 1 — WHY Grist 1.7.18 refuses every org-level access write — is a one-way-door ruling I cannot make or prove here.** - **Not provable on this host (ADR 0174 rule 1b fails).** There is no live Grist on matou-workstation, and the only in-repo Grist is the double, which the ticket shows is wrong about the box (it accepts the writes Grist refuses). A green `go test` here would prove nothing — the #1574 trap. The real reason needs the next **live re-drive** (a rented droplet), which the diagnostic above now makes it capture. This is not a two-box live drive a one-shot session runs. - **The repair is a one-way door either way.** Two candidates, both product-surface: 1. **`GRIST_DEFAULT_PRODUCT` in the render** (`internal/clan/datacollections.go`) — changes what a deploy does and what *every* community's data-collections site IS. A new deploy default. 2. **Move #1535's posture off org-level to workspace/doc level** — the level the evidence shows *does* accept writes — which **reopens your #1535 ruling** ("one community sign-in, every door; an operator is admin everywhere / org owner"), because workspace access is a weaker promise than org owner. **Proposed default ruling (adopt whichever you prefer, or a third):** - **(A)** Keep the org-owner posture and add `GRIST_DEFAULT_PRODUCT` (the "Free"/team product that permits user adds) to the render — smallest change, preserves the #1535 promise — *pending confirmation from the next drive's captured 403 body that a default-product denial is in fact the cause.* - **(B)** If the body shows the org simply cannot take org-level grants in this single-org config, re-shape #1535 for Grist to workspace/doc-level owner (the operator owns the community workspace, not the org). You already own the whakatohea-demo Grist org, so you may be able to rule now without the re-drive. **Re-drive note:** the leg only goes green once Defect 1's repair also lands — Defect 2 alone correctly leaves data-collections outstanding while it genuinely 403s. The drive's box is released; the live leg re-proves on the next drive. Leaving `ready-for-human` for the Defect-1 ruling.
Owner

Evidence from the kept box (170.64.140.199, drive 20260918T074206Z) — Grist's own 403 body, read live 2026-09-18 ~13:35Z. No ruling here; this is the fact the ticket said was missing.

Replayed the health seed's exact write on the box's local serve port with the minted owner key (/var/lib/data-collections/state/owner-api-key):

PATCH /api/orgs/data-collections/access   {"delta":{"users":{"everyone@getgrist.com":"editors"}}}
→ HTTP 403   {"error":"This user cannot share with everyone at top level"}

And the org record (GET /api/orgs/data-collections):

"billingAccount":{… "product":{"id":1,"name":"Free","features":{"workspaces":true,"vanityDomain":true}} …},"access":"owners"

What this settles:

  • The GRIST_DEFAULT_PRODUCT hypothesis (proposed ruling A) is disproved. The team site already rides the Free product with team features and no share caps. The refusal is not a product/seat limit.
  • The refusal is about the PRINCIPAL, not org-level writes in general. grist-core only lets its support user grant everyone@getgrist.com on a top-level resource; any other owner gets exactly this 403. Because the operator is already owners on the box, the read-first seed (#1574) computes a delta of only everyone → editors, so every one of the 36 attempts is this one refused write.
  • NOT verified: that the roles reconciler's per-person proof-operator → owners write is refused too. The ticket infers it from the missing setRole log lines; nobody has observed its response. I did not replay it (it would likely succeed and mutate the box). f541461c's body capture will show it on the next drive.

So the real choice for #1535's "every member an editor" on Grist is between:

  1. Per-person, no everyone — the member-orbit port (#1551) already reconciles a person into the org; seed each member as editors at add/approve and drop the everyone seed + its health assert. Keeps org-owner for operators. Needs the unverified per-person write to work.
  2. Make the seeding identity Grist's support user (GRIST_SUPPORT_EMAIL = the install owner) so it MAY share with everyone at top level — keeps the current posture, but the support user carries other special-cased behaviour in grist-core that would need reading first.
  3. "Workspace/doc level" (the ticket's option 2) likely hits the same wall for workspaces — the error says top level, and grist-core applies the same guard to workspaces; only doc-level everyone is open to ordinary owners.
**Evidence from the kept box (`170.64.140.199`, drive `20260918T074206Z`) — Grist's own 403 body, read live 2026-09-18 ~13:35Z. No ruling here; this is the fact the ticket said was missing.** Replayed the health seed's exact write on the box's local serve port with the minted owner key (`/var/lib/data-collections/state/owner-api-key`): ``` PATCH /api/orgs/data-collections/access {"delta":{"users":{"everyone@getgrist.com":"editors"}}} → HTTP 403 {"error":"This user cannot share with everyone at top level"} ``` And the org record (`GET /api/orgs/data-collections`): ``` "billingAccount":{… "product":{"id":1,"name":"Free","features":{"workspaces":true,"vanityDomain":true}} …},"access":"owners" ``` What this settles: - **The `GRIST_DEFAULT_PRODUCT` hypothesis (proposed ruling A) is disproved.** The team site already rides the `Free` product with team features and no share caps. The refusal is not a product/seat limit. - **The refusal is about the PRINCIPAL, not org-level writes in general.** grist-core only lets its *support user* grant `everyone@getgrist.com` on a top-level resource; any other owner gets exactly this 403. Because the operator is already `owners` on the box, the read-first seed (#1574) computes a delta of *only* `everyone → editors`, so every one of the 36 attempts is this one refused write. - **NOT verified: that the roles reconciler's per-person `proof-operator → owners` write is refused too.** The ticket infers it from the missing `setRole` log lines; nobody has observed its response. I did not replay it (it would likely succeed and mutate the box). `f541461c`'s body capture will show it on the next drive. So the real choice for #1535's "every member an editor" on Grist is between: 1. **Per-person, no `everyone`** — the member-orbit port (#1551) already reconciles a person into the org; seed each member as `editors` at add/approve and drop the `everyone` seed + its health assert. Keeps org-owner for operators. Needs the unverified per-person write to work. 2. **Make the seeding identity Grist's support user** (`GRIST_SUPPORT_EMAIL` = the install owner) so it MAY share with everyone at top level — keeps the current posture, but the support user carries other special-cased behaviour in grist-core that would need reading first. 3. "Workspace/doc level" (the ticket's option 2) likely hits the same wall for workspaces — the error says *top level*, and grist-core applies the same guard to workspaces; only doc-level `everyone` is open to ordinary owners.
Owner

Ruled by Ben (in session, 2026-09-18): option 1 — per-person, no everyone. Landed as 8d69f1b3.

  • The gristFake double was moved onto the box FIRST: it now refuses any org-level everyone@getgrist.com grant with the box's own 403 {"error":"This user cannot share with everyone at top level"} — red against the old seed, exactly the drive's failure.
  • The deploy-time health check seeds and asserts the founding access only (operator → owner). The everyone → editors seed and its assert are gone.
  • member.RoleMapping.MembersAtDeploy (set by the Grist port): ReconcileService now seeds every CURRENT member (active / yet to sign in — never removed, suspended or awaiting approval) when the port deploys, beside the member add/approve reconcile that already wrote a plain member in per person.
  • GOTCHAS #245.

Still unverified live: that Grist accepts the per-person PATCH keyed by a bare kanidm username — drive 20260918T074206Z showed proof-member and proof-operator both not_applied on data-collections, on a build that did not yet log refusals. If that write is refused too, f541461c's body capture will name why on the next drive and it comes back as its own ticket. Closing this so the #1547 blocker lifts and the armed cron queue re-fires.

**Ruled by Ben (in session, 2026-09-18): option 1 — per-person, no `everyone`.** Landed as `8d69f1b3`. - The `gristFake` double was moved onto the box FIRST: it now refuses any org-level `everyone@getgrist.com` grant with the box's own `403 {"error":"This user cannot share with everyone at top level"}` — red against the old seed, exactly the drive's failure. - The deploy-time health check seeds and asserts the founding access only (operator → owner). The `everyone → editors` seed and its assert are gone. - `member.RoleMapping.MembersAtDeploy` (set by the Grist port): `ReconcileService` now seeds every CURRENT member (active / yet to sign in — never removed, suspended or awaiting approval) when the port deploys, beside the member add/approve reconcile that already wrote a plain member in per person. - GOTCHAS #245. **Still unverified live:** that Grist accepts the per-person `PATCH` keyed by a bare kanidm username — drive `20260918T074206Z` showed `proof-member` and `proof-operator` both `not_applied` on data-collections, on a build that did not yet log refusals. If that write is refused too, `f541461c`'s body capture will name why on the next drive and it comes back as its own ticket. Closing this so the #1547 blocker lifts and the armed cron queue re-fires.
ben closed this issue 2026-09-18 13:49:04 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#1575
No description provided.