only kill stale model instances when there's _any other type of sessi… - #6
Closed
lukemarsden wants to merge 1 commit into
Closed
only kill stale model instances when there's _any other type of sessi…#6lukemarsden wants to merge 1 commit into
lukemarsden wants to merge 1 commit into
Conversation
…on_ waiting to be handled
lukemarsden
added a commit
that referenced
this pull request
Mar 18, 2026
Issue #1 (stuck "Starting Desktop"): - Add defer in StartDesktop to clear external_agent_status on any error - Give waitForDesktopBridge its own 90s context decoupled from dockerCtx Issue #4 (status not cleared on stop): - StopDesktop unconditionally clears external_agent_status and status_message Issue #5 (no restart button in Starting state): - Frontend: show Stop button in "starting" state in both screenshot and stream modes - Show "may have failed to start" message after 2-minute timeout Issue #10a (duplicate sessions per spectask): - Re-read task from DB before CreateSession; skip if PlanningSessionID already set Issue #10b (scanner targets wrong sessions): - processPendingPromptsForIdleSessions now filters to canonical planning_session_id only Issue #2 (duplicate message sends): - Add ClaimPromptForSending() atomic store method (UPDATE WHERE status IN pending/failed) - Both interrupt and any-pending delivery paths use claim before send Issue #7 (promotion race gives empty zvol): - resolveDockerDataDir: acquire read lock before fresh zvol creation; re-check after Issue #3: Already handled by existing open_thread on agent_ready reconnect Issue #6: Fixed in merged PR #1947 (RecoverStaleBuilds 60s retry) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Spec-Ref: helix-specs@04b515c3c:001588_read-helixs-design2026
binocarlos
added a commit
that referenced
this pull request
Jun 10, 2026
…ined User pushback on the previous "child renders parent's interactions inline by fetching them" approach was correct: it works for one level of fork, but fork-of-fork would only see the IMMEDIATE parent's turns, not the full ancestry. A fork should be a complete snapshot of the conversation at the moment it was taken. Design change: when forking, copy every non-fork_seed interaction from the parent into the child as a real interaction row, marked with the new Trigger=fork_inherited. The child then owns its full history natively — no chain-walking, no cross-session fetches. A fork-of-fork falls out for free: B's interactions are [A's inherited copies, B's fork_seed, B's own turns]. When forking B → C, the helper copies B's non-fork_seed rows, which means C inherits A's turns (via B's copies) PLUS B's own turns, with C's own fork_seed marking the new boundary. Test TestForkSessionFromParent_ChainDepth2PreservesFullAncestry covers this exact case. maybePrependTranscript is unchanged: fork_seed.response_message still carries the serialized blob used to seed the agent on first message (Zed thread starts fresh and can't read helix DB rows). The inherited interaction rows are for UI display; the prepend is for agent context. Both layers stay in sync because they share the same parent-interaction source at fork time. Frontend: revert the parent-fetch logic from the previous commit (now obsolete — the inherited rows render through the existing visibleInteractions path). Test updates: existing assertions of "child has 1 interaction" become "1 + N inherited" — verified across snapshot, override-app, empty-parent, and recursive-strip tests. memorystore's ListInteractions already supports the per-session filter so no store changes needed. Verified end-to-end in the inner Helix on task #6 (Copy semantics test): created a Claude Code session that responded "A robot learned to love…", forked to test2 → the inherited prompt and the agent's reply both render as proper chat bubbles in the child, followed by the fork_seed divider and the new chat input. Spec-Ref: helix-specs:002082_what-i-want-to-do-is
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…on_ waiting to be handled