Skip to content

fix: enforce device leases for daemon sessions#886

Closed
thymikee wants to merge 3 commits into
mainfrom
advisor/003-daemon-session-lease-admission-cleanup
Closed

fix: enforce device leases for daemon sessions#886
thymikee wants to merge 3 commits into
mainfrom
advisor/003-daemon-session-lease-admission-cleanup

Conversation

@thymikee

Copy link
Copy Markdown
Member

Summary

Bind daemon sessions to lease ownership metadata so follow-up commands can admit against the stored session lease, heartbeat activity, release on close, and reclaim expired leased sessions.

Adds shared lease-scope merge/proxy validation helpers and keeps DeviceLease as the daemon registry vocabulary with SimulatorLease as a compatibility alias.

Validation

pnpm format passed.

pnpm typecheck passed.

pnpm exec vitest run src/daemon/__tests__/request-execution-scope.test.ts src/daemon/__tests__/request-router-open.test.ts src/daemon/__tests__/request-router-lock-policy.test.ts src/daemon/__tests__/session-store.test.ts passed, 48 tests.

pnpm check:unit was attempted twice: sandboxed run failed with localhost listen EPERM; escalated run reduced to five unrelated platform/exec timeout or mocked-tool failures outside the Plan 003 path.

@github-actions

Copy link
Copy Markdown

Size Report

Metric Base Current Diff
JS raw 1.3 MB 1.3 MB +2.2 kB
JS gzip 437.1 kB 437.5 kB +343 B
npm tarball 575.0 kB 575.3 kB +318 B
npm unpacked 1.9 MB 1.9 MB +2.2 kB

Startup median (7 runs, lower is better):

Scenario Base Current Diff
CLI --version 25.7 ms 25.5 ms -0.2 ms
CLI --help 45.5 ms 45.6 ms +0.1 ms

Top changed chunks:

Chunk Raw diff Gzip diff
dist/src/9722.js +3.1 kB +726 B
dist/src/cli.js -894 B -391 B
dist/src/session.js +142 B +63 B
dist/src/cli-help.js -151 B -55 B

@thymikee

Copy link
Copy Markdown
Member Author

Closing as superseded by #890, which integrates the lease contract, proxy connect, session admission/expiry, and diagnostics work. Please continue review there.

@thymikee thymikee closed this Jun 26, 2026
@github-actions

Copy link
Copy Markdown
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-06-26 11:35 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant