Skip to content

refactor: remove unrestricted session upsert and deletion - #3153

Closed
thymikee wants to merge 44 commits into
refactor/session-fixture-lifetimes-corefrom
refactor/session-fixture-lifetimes-routes
Closed

thymikee wants to merge 44 commits into
refactor/session-fixture-lifetimes-corefrom
refactor/session-fixture-lifetimes-routes

Conversation

@thymikee

@thymikee thymikee commented Oct 3, 2026 •

Copy link
Copy Markdown
Member

Summary

Remove unrestricted SessionStore.set and address-only delete. Routes and integration fixtures now publish a new lifetime, update a captured ref with named fields, or retire that ref. This completes the caller migration from #3116; field-ownership enforcement follows.

The concurrency harness retains each published lifetime through cleanup. Provider fixtures expose publishSession instead of an upsert. Scenario resets retire explicitly; redundant re-sets disappear. Eighty-eight files changed, including one production module. Stacked on #3152.

Validation

Validated a6fd685348: quick checks, 311 focused/provider tests across 78 files, and Fallow pass. Independent read-only review found no weakened assertions or lifetime errors.

pnpm check:affected --base refactor/session-fixture-lifetimes-core --run passes all selected runnable gates and 2,091 tests across 317 files.

A cumulative run passed 6,430 tests before an unchanged shared TMPDIR assertion failed; that separate gate then passed all 25 controls. The final full gate remains required. CI is pending; this layer adds no device route.

Review in cubic

@github-actions

github-actions Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

Size Report

Metric Base Current Diff
Installed (including dependencies) 4.96 MB 4.96 MB -137 B
Package (unpacked) 4.96 MB 4.96 MB -137 B
Package (download) 1.49 MB 1.49 MB -22 B

Startup median (7 runs, lower is better):

Scenario Base Current Diff
CLI --version 20.6 ms 19.9 ms -0.7 ms
CLI --help 55.7 ms 55.3 ms -0.4 ms

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 88 files

Re-trigger cubic

@thymikee

thymikee commented Oct 3, 2026

Copy link
Copy Markdown
Member Author

This PR is ready at a6fd685. The change only removes the unrestricted session upsert and delete methods, and the typecheck confirms no caller is left. All 14 checks pass, and there are no conflicts. Not blocking: the planted-violation strings in session-resource-ownership.test.ts still use sessionStore.set(name, {...}), which no longer exists. The scanner keys on resource field construction, so the test still passes. You can switch them to sessionStore.update(ref, {...}) or leave them. I did not read every test-file hunk, I did not run the tests locally, and I rely on the green checks. Merge #3152, the base of this stack, first, and then this PR can land.

@thymikee thymikee added the ready-for-human Valid work that needs human implementation, judgment, or maintainer merge label Oct 3, 2026
@thymikee
thymikee added this pull request to stack #3146 October 3, 2026 13:46
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch from 26f32c6 to fac2276 Compare October 3, 2026 14:41
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-routes branch from a6fd685 to 7a53be3 Compare October 3, 2026 14:41
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch from fac2276 to 6822c67 Compare October 3, 2026 15:16
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-routes branch 2 times, most recently from 50a3e96 to 8b08557 Compare October 3, 2026 16:41
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch from 6822c67 to 4f71a3a Compare October 3, 2026 16:41
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-routes branch from 8b08557 to 4aa8123 Compare October 3, 2026 16:56
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch 2 times, most recently from 3a1c1eb to a42feba Compare October 3, 2026 17:49
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-routes branch from 4aa8123 to 0843195 Compare October 3, 2026 17:49
@thymikee
thymikee removed this pull request from stack #3146 October 3, 2026 19:38
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch from a42feba to 5fd249b Compare October 3, 2026 19:39
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-routes branch from 0843195 to 1f6b774 Compare October 3, 2026 19:39
@thymikee
thymikee added this pull request to stack #3187 October 3, 2026 19:45
@thymikee
thymikee removed this pull request from stack #3187 October 3, 2026 20:59
@thymikee
thymikee force-pushed the refactor/session-fixture-lifetimes-core branch from 5fd249b to 0f7487f Compare October 3, 2026 21:00
@thymikee

thymikee commented Oct 3, 2026

Copy link
Copy Markdown
Member Author

Consolidated into #3152 as part of reducing #3116 to seven PRs. The composition preserves the complete pre-consolidation source tree, including tests and later review corrections. This PR is superseded; its review discussion and native evidence remain available. Outstanding findings transfer to the owning keeper in the implementation record.

@thymikee thymikee closed this Oct 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Valid work that needs human implementation, judgment, or maintainer merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant