Repository navigation
fix: preserve member identity through dispatch and continuation - #11018
Conversation
|
Intent: Let a conductor reliably dispatch work to named members, receive completion callbacks, and continue their conversations with the original template and private memory. Keep member conversations accessible and their working status accurate while delegated work runs. |
Design Review (Fable 5) — 🟡 CONCERNSDesign-level review of Design-Verdict: CONCERNS One 9,400-line commit couples independent fixes — shell-gate boundaries, glibc renameat2 fallback, sandbox retry, KAS readiness — to the member-identity change; any regression reverts all of them. Watch
[DESIGN-REVIEWED] 2597b4e |
UX Review (Fable 5) — ✅ PASSUX-level review of UX-Verdict: PASS Verify the roster's green dot on a delegated-only member reads as "busy", not "replying" — the disambiguating label appears only after selecting the member. Suggestions
[UX-REVIEWED] 2597b4e |
GPT 5.6 Review — ✅ no blocking findingsGPT 5.6 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
First Principles Review (Fable 5) — 🟡 CONCERNSPremise-level review of First-Principles-Verdict: CONCERNS KAS session start now fails closed on wire semantics grounded in two captured kiro-cli releases, and the docs themselves admit one load-bearing behavior "was not probed". Not justified as shipped
What this change shipsInventory (10 items, capped — the change has more) — 9 justifiedIntent: keep a delegated crew member's identity, private memory and tools intact through dispatch, continuation and gateway restart — a FIX, with declared supporting capabilities riding along.
[FIRST-PRINCIPLES-REVIEWED] 2597b4e |
Opus 4.8 Review — ✅ no blocking findingsReviewed Review detailsBoth candidates fail falsification: CANDIDATE 1 ( CANDIDATE 2 (transiently-unreadable selection file downgrades pinned model to auto): The trigger — a momentary I/O error / permission blip on No new findings survived grounding. No findings. [OPUS-REVIEWED] 2597b4e Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
Security Scope Review -- 🟡 CONCERNSWhich legitimate operations does Verdict basis: the reviewer's own judgement; no confirmed regression. Security scope review -- adjudicated candidates
No candidate flipped from allowed to refused. Scope-Verdict: CONCERNS TIGHTENING: ADJUDICATED: 24 candidates, 0 confirmed newly-refused PLATFORM COVERAGE: posix -- 14 rows covering the bash-specific shapes the diff's lexing assumes (heredocs, single/double-quoted newlines, UNADJUDICATED: Three tightenings in this PR live outside the shell deny composite, so no candidate row can obtain a verdict on them:
[SCOPE-REVIEWED] 2597b4e |
|
rebutted — span=3a14e5b65fb2
|
|
rebutted — span=58d31c272e6a
|
|
rebutted — span=81c4285653d6
|
3384274 to
d8e02c5
Compare
|
fixed — span=5981637633a9
|
|
fixed — span=a80b5fa1ab8c
|
|
fixed — span=cafdb61171cb
|
|
fixed — span=758d26518290
|
|
fixed — span=60eee5df9fed
|
|
Please address merge conflict. Thanks. |
|
needs-a-decision — span=c021e3dc4eb5
|
|
rebutted — span=8c72ad6ab1e1
|
|
rebutted — span=dad9ffb4ffea
|
|
needs-a-decision — span=d6b5930ddb4c
|
Problem / Motivation
Private member work can lose its tools or identity between delegation, completion callbacks and gateway restart. A new worker may have member metadata but no protected private-memory assignment. A continuation can resume its native session yet fail memory calls, inherit the conductor's template, or reject the directory it already uses. Members can refuse to reopen a running conversation. Creation must not let a private caller assign work to another member's memory.
Why it matters
Owners need to continue the same task with the same private memory. They need to reopen member conversations and see when delegated workers are still busy. A failed identity check must not silently select global memory.
What changed (motivation → approach → change)
Keep member identity and agent selection in protected records, separate from editable history. Dispatch publishes the selected namespace and private assignment before execution. A named
crewstays distinct from its template through admission, queueing and allocation. A template override changes one turn, not the member identity restored by continuation. Failed-run retries retain the known member. Private callers create only same-store workers; Global callers retain member assignment. Creation checks the canonical caller key before allocation and rechecks its live identity after awaited preparation. Continuation retains the original selection, app owner, project and memory mode. Agent switches save a revision-checked choice; failed writes, cancellation and failed private grants restore the committed choice before releasing locks. Restored conversations use that record. Private tools still require process, session and store proof.Effort receipts resolve the same member/template namespace as execution; unknown identity omits a verdict instead of guessing. The run list shows the crew name when no explicit template was supplied, so retaining an empty override does not erase the member label.
Make required KAS tools ready before prompting. Carry compatible managed-server declarations in the session request with their trusted gateway and caller identity. Wait for connection and permitted tool exposure without resetting the full MCP report. Session-owned status frames retain external server failures, authorization needs and reconnect state. Failed fresh sessions are terminated; failed resumes preserve native history. New conversation creation waits for memory startup within the existing grace period.
Keep member conversations accessible while work runs. Members can reopen a verified live assignment, including approval waits, and see child-only activity. Channel commands pass the parent's verified memory store into admission. Continuing in the current pool default omits a redundant directory override; a different recorded directory still passes current directory policy. Refusal text distinguishes a linked session from a mismatched private assignment; running alone is not an error. Supporting shell and private-filesystem fixes preserve existing safety checks.
mcp_tools/spawn.py,dashboard/session_control.py,session_allocation.pycrew, validate private delegation, publish selection and pin assignment before birth metadata; drain cancelled writes.subagent_manager/run.py,subagent_manager/continuation.py,subagent_manager/admission/pump.py,subagent_persistence.py,subagent.py,dashboard/token_auth.pymessaging/commands.pyconfig/loader.py,session.py,session_agent_selection.py, dashboard chat pathsacp/runtime.py,acp/kas_agents.py,acp/mcp_session_report.pyMembersPage.tsx,website/src/i18n,dashboard/handlers/members.pysecurity/shell_normalizer.pysandbox.py,platform_compat.py🟩 added · 🟨 changed · 🟥 removed · 🟦 unchanged
Owning
docs/system-specs/,docs/architecture/mcp.mdand packagedsrc/kiro_crew/docs/configuration.mddocument behavior and refusal paths. Supportingcontext.py,agent.py,agent_capabilities.py,agent_state.py, provider and session-map changes carry the same identity through context preparation and allocation.Tests
Candidate
2597b4e124c1ae73b866bc631cd5c0102e44442e, one commit based on main2a138cc4cc388446108196c1d6735d14a8a3d1d2. The rebase preserves the reviewed member fixes and original author. Its sole conflict was a Windows pod fixture: it retains bothIS_LINUX=Falseand upstream's Task Scheduler probe stub.git range-diffconfirms the rest of the patch is unchanged.743ac744also returned No findings. They are retained evidence, not relabeled as reviews of this SHA.On
743ac744, all four Linux and eight Windows backend shards, frontend shards, E2E, static checks, Coverage Combine and Coverage Gate passed. The two on-demand macOS shards failed six provider-reaping cases and five invalid-byte pathname fixtures; all affected files match that head's base. The ledger count failure did not recur, which does not prove its root cause fixed.The separate Darwin repair #11491 remains unmerged. Its native run on
7ea8a011eliminated all six provider-reaping failures; its remaining macOS failures are the five pathname fixtures. Its Linux failure is the Windows pod fixture corrected on this base. The pathname failures remain reported upstream. No unmerged upstream repair, relaxed assertion, additional skip or longer timeout is included here. Fresh hosted checks and reviews must validate this rebased candidate; all-checks-green is not yet claimed.Test floors in
conftest.pyandtest/conftest.pyisolate filesystem and model state; the formatted default-model test leaves.github/black-baseline.txt.Manual verification
Current private-delegation tests use real slots, protected bindings and persisted history with simulated providers. No real private memories or live gateway settings were used.
The original author supplied authenticated real KAS create/load evidence with public CLI 2.21.4 through a normally installed
0ddf13b5a725e9bd894ac985e6b65d4a9147188fwheel. A fresh process resumed the same native session after the original process stopped; both phases reached managed-server connection and tool exposure, with zero model prompts. ACP treec4baa15ea5adb1fab98fbca253ddececb06c7ed7was byte-identical to0bf8d2263a9e. The current ACP tree also includes upstream scratch-boundary and owner-marker handling changes; the earlier native probe is not whole-tree proof of this candidate. Wheel SHA-256:aef2970625fbe5051e707bf2bd9a35e1a38cd9ff1b9a59c9a3f8473c584df357. The author checked 4,351 installed package files against the wheel and source/assets. Author evidence. This is author-supplied transport/readiness proof, not independently rerun here or a new private execution proof. Native Windows/macOS were not run locally.The initial same-runtime load probe timed out on tool exposure and remains recorded. The passing fresh-runtime load follows the production
AcpProvider._start_kiro_runtime_impllifecycle.Historical evidence from the installed
af24043d9767build remains historical: 84 orchestration audit checks with public CLI 2.21.4 on Linux; three accepted/done/pass member tasks; reports of 109 tests passed and one slow-test skip; separate private stores; explicit-project worker recall and same-conversation continuation after gateway restart. Normal approvals were supervised. An initial brief incorrectly prohibited fresh-spawncwdand failed imports; the corrected assignment supplied it. Memory used keyword mode, not an embedding-ranking or consolidation test. Older real CLI 2.18.0 probes covered allowlists, exclusions and missing executables; CLI 2.20.0 separately reported client origin for explicit injection. These are not new tests of this candidate.Compatibility limits: managed declarations whose fields cannot cross session transport (
disabledTools,timeout, registry metadata) remain in the agent definition. CLI versions without origin metadata cannot safely admit them. CLI 2.19 remains untested. Protected selection records remain for a conversation key's lifetime, including after transcript deletion.Accepted upgrade limit / release-note handoff: pre-upgrade protected run records missing
appownership returnresume_failedafter registry eviction or gateway restart. Start a fresh conversation; transcript files are not deleted. Still-registered original runs retain their existing ownership fallback. The maintainer explicitly accepted this limit and authorized the same-store delegation fix in the decision record. The release PR that ships this change should disclose it; this feature PR does not edit shipped changelog sections or infer missing ownership.The author reported a separate background-consolidation refusal in an earlier isolated run. A clean-main runtime reproduction and embedding-quality verification remain absent; direct persistence/recall do not prove those paths.
The unchanged syscall helper passed a real glibc 2.26/x86_64 probe in an official Amazon Linux 2 container: libc lacked
renameat2, the raw syscall renamed successfully, and EEXIST preserved both the destination inode/content and the source. Python 3.7.16 served as the helper harness, not application boot. Compatibility evidence.A credential-free container with SHA-256-verified public CLI 2.22.0 refused both supported auth modes before ACP initialization because login was absent. No host home, credentials, private memory or model prompts were used. That attempt remains inconclusive; the authenticated author evidence above supplies create/load proof. Evidence request.
The base includes the ledger repair and PR #11442, which fixes the inherited Fargate protocol failure. No unrelated cloud or macOS process-control fix is folded into this patch.
Screenshots / video
Historical captures from installed
af24043d9767, retained as prior evidence, not relabeled as current-head screenshots. Members source is unchanged by the authorization patch. “Operator intervention: none” refers to corrective team assignments; normal approvals were supervised. Account counters were redacted by the author.Related Issues
no linked issue: fixes member execution failures reproduced during the original workflow and review.
Pattern harvest
Rule candidate: review-prompt
Pattern: Preserve protected continuation identity, authorize a child before allocating it, and recheck mutable caller identity after awaited preparation.
Checklist
feat|fix|docs|refactor|perf|test|chore|ci|build|revert: ...)