feat: pin sessions to workspace revisions
This commit is contained in:
@@ -26,6 +26,29 @@
|
||||
completed with 22 passing tests.
|
||||
- `git diff --check` completed cleanly.
|
||||
|
||||
## Review fixes — round 2
|
||||
|
||||
- Lifecycle authorization no longer selects the installation-default workspace. The backend now
|
||||
finds each session by querying every operational registry snapshot with the authenticated
|
||||
principal, preserving RLS ownership concealment.
|
||||
- After locating the manifest, durable pinned sessions resolve their retained descriptor before
|
||||
any lifecycle mutation/reopen. Legacy sessions continue using the locating registry snapshot.
|
||||
- Session listing aggregates the owner-visible rows from all operational registry snapshots;
|
||||
detail, response, steer, resume, events, documents, and lifecycle mutations use the same
|
||||
server-side locator. No route depends on browser-local workspace state.
|
||||
|
||||
### Round 2 verification
|
||||
|
||||
- RED: the new cross-workspace route integration test created a B session while installation
|
||||
default A was selected, then demonstrated that `GET /sessions` returned an empty list.
|
||||
- GREEN: `npx vitest run test/routes-sessions.test.ts test/tht-runner.test.ts test/routes-settings.test.ts && npx tsc --noEmit -p .`
|
||||
— 101 tests passed with a clean type check. The integration test covers create B, list, detail,
|
||||
response, and resume through B's pinned descriptor while default A remains configured.
|
||||
- Full backend suite: 342 tests passed. The remaining 7 tests require binding `127.0.0.1` and
|
||||
fail in this sandbox with `listen EPERM: operation not permitted`; no application assertion
|
||||
failed. The focused typecheck above passed.
|
||||
- `git diff --check` completed cleanly.
|
||||
|
||||
## Verification note
|
||||
|
||||
The unscoped backend suite was also run. The Task 7 code regressions in `test/tht-runner.test.ts`
|
||||
|
||||
Reference in New Issue
Block a user