Repository navigation
feat(people): see each guest's patches and remove them from all - #1115
Conversation
Sol reviewReviewed
Standards: no additional findings. The port is wired in the server; the guest projection is one joined query decoded through Schema; the new tests use real services and focused behavior assertions. The shared table/details and confirmation components fit the shell. Other spec checks: members see no Remove and their GET/POST are refused; the new POST rejects foreign and missing origins; revocation is company-scoped, active-only and soft. Current-only email visibility and name fallback are preserved. I accept excluding people whose grants have all ended, reusing the shell's expandable row, and Verification: all 40 tests across the server Guests, auth CompanyPage and GuestGrants suites passed. Three temporary, uncommitted probes reproduced the two findings and verified the new POST's CSRF refusal. No tracked files changed or commits pushed. Verdict: request changes — two should-fix findings; no blockers or nits. |
|
Sol review, finding 1 (disabled grants), fixed in 697f567. People's Guests now lists every active grant, including grants on disabled patches, in the same single Schema-decoded query. A disabled patch shows its title, without a link, and an Unavailable pill. A guest whose patches are all disabled stays listed and removable, and the confirmation lists every grant |
|
Sol review, finding 2 (confirmation wording), fixed in 697f567. The confirmation now reads: "Jo Rivera’s guest access to these ends. Public ones stay open to anyone with the link. Their Pine Studio account stays as it is." |
Sol re-checkRe-checked Findings: no blockers, should-fix findings or nits. Both earlier findings are fixed.
Members still see guests without Remove; confirmation GET/POST return 403. Foreign/missing Origin POSTs return 403 without changing grants. Member patch access remains intact. Verification: 42 existing tests across Guests, CompanyPage and GuestGrants, plus three temporary reproduction probes, all passed against an isolated head snapshot. No checkout edits or pushes. Verdict: approve this fix. No regression found in the reviewed scope; full CI is still running. |
697f567 to
f760386
Compare
0a524a1 to
673c601
Compare
Acceptance: PASS with notesChecked Done means
Rebased main interactions / rendering
Golden journeys: passed
Focused tests Rollback answers: match the diff. No migration, descriptor, API/CLI or infrastructure change. Remove-all leaves ordinary revoked grant rows that the previous slice understands; re-sharing restores them. This slice alone needs no Not run / notes
|
673c601 to
b1008ce
Compare
People gains a Guests tab, shown to every member once the company has guests: one row per person at another company holding a grant to one of its patches now, with their company. Each row opens, with the shell's expandable table row, to the patches shared with them, who shared each and when. Admins get Remove from all patches…, a confirmation listing those patches, which ends every grant the person holds in this company and leaves their grants elsewhere alone. Members never see it, and their GET or POST of it is refused. Companies can't depend on Patches, so CompanyPage declares a Guests port that the server fills from GuestGrants: companyGuests, one read decoded through Schema, and revokeAll, one soft-revoking UPDATE. Someone whose grants have all ended isn't listed. Co-authored-by: Srikar Voleti <[email protected]> Co-Authored-By: Claude Opus 5.5 <[email protected]>
… says what ends People's Guests now lists every active grant, a disabled patch's too, marked unavailable, so a guest whose patches are all disabled can still be removed and the confirmation lists every grant Remove ends. The confirmation says the person's guest access ends and that public patches stay open to anyone with the link. Co-authored-by: Srikar Voleti <[email protected]> Co-Authored-By: Claude Opus 5.5 <[email protected]>
f760386 to
e620811
Compare
## What changed This adds release 31's What's new entry, written from `5888411`. It covers everything merged since release 30's `through` (`e3d50f0`). It also sets the `patchy` release to `0.31.0` in `packages/patchy/package.json` and `CURRENT_RELEASE`. | Change | PRs | | --- | --- | | New: share a patch with someone at another company from Share… in its menu. They open it as themselves, find it under Shared with you, can be picked wherever the patch asks for a person, and on a server-code patch reach only what its builder opened to guests. The company-or-internet choice moved into the same dialog, and agents can share too | #1108, #1110, #1113, #1114 | | New: People has a Guests tab, with each guest's patches, and admins can remove a guest from all of them at once | #1115 | | New: admins can block guests from a connection, and owners see why on the patch's card | #1112 | #1118 is release 30's own entry. ## Look at - **The entry**, at the top of `releases` in `packages/core/src/whatsNew.ts`. The four PRs that make sharing work are one change, since nobody can share before Share… exists. - **Rollback safety, from the live commit `54438fa` (release 30) to `5888411`:** the same six PRs. #1108, #1110, #1112 and #1113 are labelled `one-way`, and their answers agree: - #1108 adds `patch_guest_grants` (migration `0031`). Release 30 starts with it but ignores grants, so every guest loses access. - #1110 adds the `guest: true` handler mark to tier 2 descriptors. Release 30's schema refuses it, so it can't load tier 2 versions published with it. - #1112 adds `block_guests` (`0032`), and #1113 adds a directory trigger (`0033`). Release 30 runs with both but would ignore admins' blocks and resolve guests picked in member columns as nobody. - #1114 and #1115 add no migration or descriptor field. **Rollback line:** Rolling back past #1110 would leave tier 2 versions published with handlers marked for guests unloadable, because release 30's descriptor schema refuses `guest: true`, and past #1108 would cut every guest off; fix forward instead. ## How it was verified - **Tests.** `whatsNew.test.ts`, `schemas.test.ts` and `WhatsNewPages.test.ts` pass (21 tests), and prettier passes on the changed files. - **The range.** Each of the six PRs was reviewed by GPT 6.1 Sol with every finding resolved, and got a fresh acceptance PASS with notes at its rebased head. Each landed with all 12 required checks green, `rollback-rehearsal` included, and its squash tree matched the accepted head. - **Deploy state.** The live commit, pinned from `/healthz/deep`, is `54438fa` (release 30). The Deploy run updated last succeeded, and none is unfinished. ## Release impact - [ ] **Breaking** — requires action from anyone already running this - [x] **Not breaking** — no action required Text and version numbers only. The `0.31.0` bump tells CLIs and patch repos installed before this deploy to upgrade, as every release does. - **What does a revert leave behind?** Nothing. - **Does the release before it still work with that?** Yes. Built by Claude Opus 5.5 (`claude-opus-5-5`) in Claude Code, through T3 Code. Co-authored-by: Claude Opus 5.5 <[email protected]>


What changed
A company could share patches with guests one patch at a time, but nobody could see who outside the company holds which of its patches, or cut one person off everywhere at once. People now has a Guests tab, visible to every member once the company has guests. Each row is one person at another company with their own company, and opens to the patches shared with them, who shared each and when. Admins get Remove from all patches…, a confirmation page listing those patches, which ends every grant the person holds in this company and leaves their grants elsewhere alone.
This is the last of six stacked PRs, on #1114.
Closes #1081
Look at
As Ada, the admin. The Guests tab, a row opened (
#guest-<id>opens it), and the confirmation. Before is PR 5's head, which has no Guests tab and answers 404 for the confirmation.Before and after, as Ada Park (admin)
Before is
0a524a1(--base origin/guests/5-share-dialog) and after is0f802ee(guests/6-people-guests), both on theguestsscenario, frompnpm dev compare./company?show=guests1280px, after
1280px, before
/company?show=guests#guest-usr_env_pine_jo1280px, after
1280px, before
/company/guests/usr_env_pine_jo/remove1280px, after
1280px, before
Failed to load resource: the server responded with a status of 404 (Not Found).Failed to load resource: the server responded with a status of 404 (Not Found).As Ben, a member. The same row, without Remove.
Before and after, as Ben Ortiz (member)
Before is
0a524a1(--base origin/guests/5-share-dialog) and after is0f802ee(guests/6-people-guests), both on theguestsscenario, frompnpm dev compare.Every page answered 200 with no browser errors.
/company?show=guests#guest-usr_env_pine_jo1280px, after
1280px, before
Decisions worth checking
table-expandrow, a native<details>whose summary says "2 patches". Matching the mock's whole-row summary with a drawn chevron would have needed a component style that People's own CSS shouldn't own. People adds layout CSS only. Remove from all patches… sits inside the opened row, as in the mock.CompanyPage.Guests(list,removeAll) is filled inapps/serverfromGuestGrants, asOwnedPatchesalready is. It's filled bycompanyGuests, one query decoded through a Schema class and grouped per person, and byrevokeAll, oneUPDATEthat setsrevoked_atfor that person in that company.How it was verified
New tests, in
apps/server/src/Guests.test.tsover the whole server. Gina, from another company, holds two of the dev company's patches and one of a third company's:holders→false. The third company's patch is still shared with her.company_idfilter fromrevokeAllfails the second test.0a524a1: typecheck and lint are clean. The server guest suite (11), the authCompanyPagesuite (24) andGuestGrants(5) pass.pnpm check: format, lint, typecheck and synth pass.testfails only in the suites that record the strayGET /this machine's T3 app sends to local ports: the CLI stub suites (cliPublish,cliLifecycle,cliLook,cliRepoPublish,cli) and execution'sLocalTaskProviderandSupervisor. None of them touches People.pnpm verify: format, lint, typecheck, synth, postgres-concurrency, cli-smoke, install and tier2-smoke pass.testfails only in the same stray-GET /suites, pluscliRepo,cliRepoRecoveryandRequestEvents.browserstopped after its first failure, on that stray/intier1.spec.ts"hostile navigation" (foreignRequestsheld"/"). 21 specs passed and 53 didn't run. No browser spec covers People.Release impact
Tick exactly one.
It adds a People tab and two routes,
GETandPOST /company/guests/<id>/remove. It adds no migration and no API or CLI change, so this PR alone isn't one-way. The stack ships as one deploy and is fix-forward.Built by Claude Opus 5.5 in Claude Code (T3 Code), rebuilding Srikar Voleti's original guest stack (#1082–#1103).
Co-authored-by: Srikar Voleti [email protected]