Skip to content

P0: fix ChatGPT↔DevSpace caller continuity, live tool projection, and evidence-chain liveness #240

Description

@James3014

Problem

Governed DevSpace work is repeatedly stalling for reasons unrelated to the target feature. #236 exposed a recurring control-plane deadlock:

  1. The live M5 DevSpace server can advertise git_commit and direct_candidate_execution_evidence while the active ChatGPT callable tool projection does not expose them.
  2. Refreshing/reopening the controller surface can change caller identity, after which the same physical Core mutation session fails with CORE_MUTATION_ACTOR_MISMATCH.
  3. There is no reliable same-actor tool-manifest refresh or explicit safe caller-rebind/continuation contract.
  4. A second DevSpace namespace may be a different host/state root entirely (for example M4/jameschen vs M5/james), so it cannot safely substitute for the original session.
  5. Evidence lifecycle semantics have also drifted from real execution lifecycle: successful workers settle as idle/completed, while direct evidence previously expected stopped/completed; mixed writer domains also could not durably narrow CLEAR domains while preserving UNKNOWN domains.
  6. Provider qualification is being treated too globally even though host generation matters: HOME, PATH, Node version, provider binary/version, auth state, DevSpace build and state root can differ by Mac.

Fresh main at issue creation: 89828be

Why this is a design bug

The current workflow couples four independent concerns too tightly:

tool-schema freshness
+ caller identity continuity
+ Core mutation provenance
+ evidence producer lifecycle

This creates a deadlock pattern:

need refreshed tool surface
-> refresh/rebind changes caller identity
-> existing Core session becomes inaccessible
-> Candidate/evidence cannot continue under original provenance
-> controller must restart governed work or create recovery plumbing

Governance should remain fail-closed, but refreshing capabilities must not routinely destroy continuity of the exact governed effect.

Evidence from #236

  • Wave-3 attempt-6 Candidate already exists: a873ddb.
  • Worker replay is not required.
  • Live M5 server catalog reported git_commit while one ChatGPT conversation had no callable git_commit method.
  • Later continuation attempts hit CORE_MUTATION_ACTOR_MISMATCH on the same physical Core session.
  • Another DevSpace namespace exposed git_commit but proved to be the M4/jameschen server/state root, so it could not legally continue M5 provenance.
  • A two-file evidence-lifecycle repair reached 25/25 focused tests, typecheck PASS, build PASS and diff-check PASS, yet Candidate formation was blocked by caller/tool binding rather than code correctness.

Relevant #236 reconciliation markers:

  • issue236-wave3-attempt6-evidence-lifecycle-blocker-20260924-v1
  • issue236-wave3-lifecycle-repair-verified-host-schema-block-20260924-v1
  • issue236-evidence-lifecycle-repair-verified-actor-rebind-blocker-20260924-v1

Required outcome

A. Same-actor capability refresh

Provide a supported way to refresh/rebind the live DevSpace tool manifest without silently changing Core actor identity. Expose at least server instance/build/source identity, client projection generation, caller identity and projection freshness.

B. Explicit continuation when caller identity must change

If same-actor refresh is impossible, provide a first-class handoff/rebind operation that binds old caller, new caller, exact workspace/session/effect identity, reconciles unresolved effects first, and preserves Candidate/evidence lineage.

C. Observable catalog convergence

The controller must be able to distinguish CURRENT, SERVER_AHEAD_OF_CLIENT, STALE_RECONNECT_REQUIRED and CALLER_REBIND_REQUIRED instead of seeing a live server tool that is simply undefined client-side.

D. Evidence lifecycle aligned to real execution

Preserve and verify the bounded fixes already identified: idle/completed is a valid successful direct-evidence lifecycle; independently CLEAR writer domains may be durably removed; UNKNOWN/ACTIVE remain unresolved; completion stays fail-closed.

E. Host-bound qualification

Provider readiness must be keyed to host identity and environment, including hostId, OS/arch, HOME, PATH, Node/runtime major, provider executable/version, auth readiness, DevSpace build/source, adapter generation and model identity.

Acceptance criteria

  1. A server update that adds a tool can reach the active ChatGPT controller without losing current Core mutation authority.
  2. If caller identity must change, there is a supported audited continuation path rather than an actor-mismatch dead end.
  3. The controller can prove whether its callable tool surface matches the live server catalog.
  4. A governed mutation can survive one tool-manifest refresh and continue through Candidate formation, direct evidence and Core verification without restarting implementation solely because of projection drift.
  5. Mixed writer-domain reconciliation narrows only proven-clear domains and never treats UNKNOWN as absence.
  6. Direct evidence accepts the actual successful worker lifecycle.
  7. Cross-host DevSpace endpoints cannot be mistaken for equivalent continuation surfaces.
  8. End-to-end regression proves no blind replay and no provenance bypass.
  9. Normal operation does not require opening a new chat merely to expose tools the already-connected server advertises.
  10. A server-generation change requires at most one deterministic refresh/rebind step, not repeated manual retries.

Non-goals

Relationship to #236

#236 should remain focused on DevSpace -> HerdR gateway behavior, durable HerdR execution identity, reconciliation, latest-main integration and acceptance.

This issue owns the recurring controller/projection/provenance deadlock that is slowing #236 and will also affect future governed work.

Priority: P0 reliability / workflow throughput.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions