Skip to content

Pi mutation-scope integration - #278

Open
davidabram wants to merge 10 commits into
opencode-mutation-scope-integrationfrom
pi-mutation-scope-integration
Open

davidabram wants to merge 10 commits into
opencode-mutation-scope-integrationfrom
pi-mutation-scope-integration

Conversation

@davidabram

Copy link
Copy Markdown
Member

No description provided.

@davidabram
davidabram added this pull request to stack #240 September 11, 2026 18:48
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 11 times, most recently from 7c01646 to 84f2a2f Compare September 13, 2026 14:24
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from 84f2a2f to f9788c8 Compare September 13, 2026 14:40
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 2 times, most recently from d55cb15 to a77e42e Compare September 16, 2026 14:48
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from a77e42e to f2c4230 Compare September 16, 2026 15:25
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 2 times, most recently from 56856c1 to a77e42e Compare September 16, 2026 16:24
davidabram and others added 2 commits September 16, 2026 22:08
Define the stacked Pi 0.80.6 integration across lifecycle evidence, confirmation-required protocol semantics, the Rust adapter, conservative recovery, extension wiring, and production regressions. Preserve false-positive safety while reusing the existing mutation-scope runtime without schema migrations.

Plan: pi-mutation-scope-integration; Tasks: T01-T06
Record reproducible captures and probe plugins for the pinned Pi 0.80.6 runtime so lifecycle, blocking, failure, ordering, signal, session, and mutation behavior can be reviewed before implementation. Update the integration plan to mark T01 complete and preserve the two design corrections discovered during probing.

Plan: pi-mutation-scope-integration.md (T01)

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 2 times, most recently from cfadb3a to 73f4ba6 Compare September 17, 2026 06:18
Prevent denied Pi tool calls from being treated as confirmed at unrelated mutation boundaries. Apply the confirmation rule across the Rust and Quint protocols, extend MBT fixtures and scenarios, add recovery coverage, and fix Scope6 exclusive attribution; record the completed plan task.

Plan: pi-mutation-scope-integration, task T02

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from 73f4ba6 to 6a5f17c Compare September 17, 2026 07:28
Track Pi's bash, edit, and write tool lifecycles through the mutation-scope
runtime with durable attempt state, fail-closed admission, terminal cleanup,
and provenance. Add the hidden Pi ingress and a harness-neutral external
mutation supervisor that keeps the worktree lock held across a spawned shell,
streams status, handles explicit cancellation, and recovers or clears taint
only after shell termination.

Document the lifecycle contract and supervisor design across the shared context
surfaces.

Plan: pi-mutation-scope-integration, task T03

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 2 times, most recently from e0dba84 to 4f4e425 Compare September 17, 2026 11:02
Preserve Pi's actual user_bash execution context while keeping guard containment fail-closed. Validate the requested cwd within the canonical worktree, mirror pinned Pi shell resolution, and drain reader threads to EOF before delivering queued output. Update the lifecycle documentation, ADR follow-up, and T03 plan evidence with contract citations and regression coverage.

Plan: pi-mutation-scope-integration (T03)

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from 4f4e425 to d4ba553 Compare September 17, 2026 12:04
Recover orphaned PendingStart attempts only when the recorded Pi owner is positively dead, using PID liveness and Linux process start-time checks to avoid TTL- or sweep-based false positives. Route stale-owner admission through the existing flush/abandon/flush recovery sequence, and add regression coverage for duplicate events, sibling isolation, interrupted recovery, external-guard reconciliation, and lock contention.

Update the Pi integration context and plan to record the D10 implementation, its conservative tradeoffs, and verification results.
Plan: pi-mutation-scope-integration, task T04

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch 2 times, most recently from 3a6e2e9 to e6774f0 Compare September 17, 2026 20:56
…egration

Add fail-closed tracked-tool lifecycle forwarding, terminal retry and recovery with explicit ToolExecutionAbandon handling, and supervisor-backed user_bash operations. Cover the extension and Rust adapter behavior with Bun and Rust tests, including Windows refusal and unresolved terminal delivery cases.

Update plan `pi-mutation-scope-integration` for T05 and T06 to record the ordinary Pi integration path and accepted extension-order limitation.

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from e6774f0 to a2f96cb Compare September 17, 2026 21:36
Expand production-path coverage for Pi mutation scopes across confirmed, failed, rejected, concurrent, and stale-process executions, including cross-harness guard races and post-recovery behavior. Replay pinned Pi captures through the real extension handlers against temporary Git repositories, and document the Linux/Windows test dispositions and competing-extension limitation.

This test-only change validates session and model provenance, conservative exclusion of ambiguous writes, guard recovery, and continued fresh-work attribution without changing production behavior, schemas, or migrations.

Ref: context/plans/pi-mutation-scope-integration.md (T06)

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from f70c7bc to 56fde7b Compare September 18, 2026 12:26
Add a credential-free end-to-end smoke that builds the current CLI, installs the real Pi extension through setup, and drives an SDK session with a faux provider through normal extension discovery and tool dispatch. Record durable Agent Trace evidence for bash attribution and session/model provenance while distinguishing runtime execution from capture-replay coverage.
Plan: pi-mutation-scope-integration (T06)

Co-authored-by: SCE <sce@crocoder.dev>
@davidabram
davidabram force-pushed the pi-mutation-scope-integration branch from 56fde7b to 00622cb Compare September 18, 2026 12:47
Pin the Quint runner seed so generated mutation traces are reproducible across runs.

Co-authored-by: SCE <sce@crocoder.dev>
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