Dashboard › opencode › Distillation
ffcd33fe-e4d8-48a4-810b-1e075d323ba7["lore_tm_v1_vVnwrld-XTDDy6CayYf3ey4KAq6YxQiAj9aZxdZ7Dso","lore_tm_v1_k8xguLOV6TSHPQReu5IOiZJ7yRugtnXYRrftRd3Uf9I","lore_tm_v1_b_F-8sJkjXF6E1OOVhRRV_5pXRYHm1zjvijlKHKKzSM","lore_tm_v1_FdDnPmN_j7vxE06rNCQLSbXfftTgQQaQ-PSEZHUpq4I","lore_tm_v1_SuXeqJP7ldWloKOXenxgIJ3zIp4KgC56y6ExPEACBEk","lore_tm_v1_v3rbdm06AxqTZ8WvmrkvdxaE_ljWbhLBYdwk4EVZFIE"]
Date: Sep 16, 2026
/tmp/opencode/session-recovery-v7-check/packages/core/test/session-prompt.test.ts includes "promotes one message once under concurrent promotion attempts": two concurrent SessionInput.promoteSteers(db, events, sessionID, Number.MAX_SAFE_INTEGER) calls produce exactly 1 EventV2.versionedType(SessionEvent.Prompted.type, 1) event, set promotedSeq: 1, and expose one user message with text "Promote once"./tmp/opencode/session-recovery-v7-check/packages/core/test/session-prompt.test.ts includes "promotes steers only through the captured inbox cutoff": after prompts "Before cutoff" and "After cutoff", SessionInput.promoteSteers(db, events, sessionID, cutoff) promotes only the first admitted input.session-prompt.test.ts confirms recorded prompts do not call execution directly: default resume and resume: true each leave executionCalls empty and produce wakeCalls: [sessionID]; resume: false leaves both arrays empty./tmp/opencode/session-recovery-v7-check/packages/core/test/session-run-coordinator.test.ts coverage visible in the supplied excerpts includes: wake while idle; coalescing wakes during active execution; interruption clearing an active executionβs pending wake; running a wake registered during interruption cleanup; forced resumption after cleanup with forces equal to [false, true]; one follow-up when wake races with failure (runs becomes exactly 2); interruption of a joined waiter not cancelling shared execution (runs remains exactly 1); concurrent execution for different keys "first" and "second"; and synchronous self-waking execution trampolined for exactly 20_000 runs./tmp/opencode/session-recovery-v7-check/packages/core/test/session-runner-recorded.test.ts configures cassette "session-runner/openai-chat-streams-text" under fixtures/recordings, recording when RECORD === "true" and otherwise replaying via HttpRecorder.http.https://api.openai.com/v1, bearer auth from OPENAI_API_KEY or fallback "fixture", model "gpt-4o-mini", maxTokens: 20, temperature: 0, project directory /project, and session ID "ses_runner_recorded"."executes one recorded V2 prompt through the recorded HTTP transport" admits "Say hello in one short sentence." with resume: false, then calls session.resume(sessionID); context contains exactly 2 messages: the user prompt and an assistant response from agent "build" with finish: "stop" and text "Hello!"."session.next.prompt.admitted.1", 2. "session.next.prompted.1", 3. "session.next.step.started.1", 4. "session.next.text.started.1", 5. "session.next.text.ended.1", 6. "session.next.step.ended.2"./tmp/opencode/session-recovery-v7-check/packages/core/test/session-runner-tool-events.test.ts uses session ID "ses_tool_event_test", agent "build", model ID "model", provider ID "provider", tool call ID "call-image", tool name "read", input path "pixel.png", MIME "image/png", and test base64 "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAB"."local tool success serializes media base64 once and reconstructs from structured content" verifies "session.next.tool.success.1" contains text "Image read successfully" plus the image file, serializes the base64 exactly once, and omits the compatibility result field for a local tool."provider-executed success retains its compatibility result" verifies a call/result marked providerExecuted: true preserves the result property in "session.next.tool.success.1"."binary failure emits no success event" uses error "Cannot read binary file" and expects no "session.next.tool.success.1" event but a "session.next.tool.failed.1" event."old success event data containing result still decodes" confirms Schema.decodeUnknownSync(SessionEvent.Tool.Success.data) remains backward-compatible with old event data containing result, decoding it as { type: "content" }."step finish records settlement without publishing step ended" publishes LLMEvent.stepStart({ index: 0 }) and LLMEvent.stepFinish({ index: 0, reason: "stop" }), expects no "session.next.step.ended.2" event, and expects publisher.stepSettlement() to contain finish: "stop"./tmp/opencode/session-recovery-v7-check/packages/core/test/session-runner.test.ts, in order: 1. line 619 "redrives only the synthetic recovery continuation"; 2. line 752 "never dispatches a provider after ownership changes"; 3. line 778 "never publishes streamed output after ownership changes"; 4. line 805 "never starts a local tool after ownership changes"; 5. line 845 "never fails interrupted tools after ownership changes"; 6. line 902 "advertises and executes a globally attached application tool"; 7. line 977 "streams one request with registry definitions from chronological V2 user history"; 8. line 1002 "retries the first provider turn after system context becomes available"; 9. line 1034 "interrupts a source Location runner after a Session moves"; 10. line 1542 "recovers the continuation committed with Compaction.Ended"; 11. line 1657 "forces one compaction and retries after provider context overflow"; 12. line 1686 "persists a second context overflow after one recovery"; 13. line 1709 "recovers once from a raw context overflow failure"; 14. line 1737 "publishes the original overflow when recovery summarization fails"; 15. line 1757 "interrupts overflow recovery while the summary provider is running"; 16. line 1819 "projects reasoning and tool events without executing or continuing tools"; 17. line 1917 "continues with reloaded history after durably settling one local tool call"; 18. line 1975 "never commits continuation before unresolved hosted tools are reconciled"; 19. line 2027 "never commits a Step end after the provider stream fails"; 20. line 2049 "keeps a running assistant recoverable when Step failure publication defects"; 21. line 2085 "durably reconciles a local tool when success publication defects"; 22. line 2124 "keeps a provider defect after Step finish unknown"; 23. line 2147 "keeps provider failure unknown until unresolved tools are durable"; 24. line 2195 "recovers the continuation committed with a settled tool step"; 25. line 2260 "reloads a model switch before a tool-driven continuation turn"; 26. line 2305 "restores durable reasoning provider metadata in a second-turn request"; 27. line 2362 "replays durable provider-executed tool results inline in a second-turn request"; 28. line 2417 "starts recorded local tools eagerly and awaits settlement before continuing"; 29. line 2478 "settles repeated provider-local tool call IDs against their owning assistant messages"; 30. line 2566 "joins concurrent resume calls into one active provider run"; 31. line 2605 "steers an active provider turn with newly recorded prompts"; 32. line 2648 "promotes queued input after continuation ends"; 33. line 2695 "preserves durable queued input for a later wake after interruption"; 34. line 2738 "preserves durable steering input for a later resume after interruption"; 35. line 2824 "promotes queued input after steering continuation ends"; 36. line 2923 "coalesces multiple active steering prompts into one continuation turn"; 37. line 2963 "runs steering input accepted while the active provider turn fails"; 38. line 2992 "durably fails local tools left running by a prior process before continuing"; 39. line 3052 "durably fails hosted tools left running by a prior process before continuing inline"; 40. line 3112 "durably fails pending tool input left by a prior process before continuing"; 41. line 3349 "durably settles local tool failures before continuing"; 42. line 3395 "returns unexpected local tool defects to the model and continues"; 43. line 3443 "returns policy-blocked tools to the model and continues"; 44. line 3492 "interrupts runner continuation when permission approval is declined"; 45. line 3606 "returns permission corrections to the model and continues"; 46. line 3655 "interrupts runner continuation when a question is dismissed"; 47. line 3711 "awaits started local tools before surfacing provider stream failure"; 48. line 3802 "durably fails blocked local tools when a provider turn is interrupted"; 49. line 3863 "retains the claim after Step interruption until runner finalizers finish"; 50. line 3918 "interrupts a blocked provider turn without local tool execution"; 51. line 3941 "durably fails blocked local tools when interrupted while awaiting settlement"; 52. line 3982 "forces a text response on an agent's configured final step"; 53. line 4030 "resets the configured step allowance when steering input promotes"; 54. line 4082 "projects provider errors as terminal assistant step failures"; 55. line 4104 "projects provider errors emitted before assistant step start"; 56. line 4123 "does not recover context overflow after durable assistant output"; 57. line 4152 "projects raw provider stream failures as terminal assistant step failures"; 58. line 4169 "does not continue automatically after a provider error follows a local tool call"; 59. line 4194 "durably fails a hosted tool when its provider errors before returning a result"; 60. line 4225 "durably fails a hosted tool left unresolved at normal provider EOF"; 61. line 4257 "durably fails a hosted tool left unresolved by a raw provider stream failure"; 62. line 4342 "rejects duplicate streamed text starts"; 63. line 4357 "transitions streamed raw tool input to parsed called input"; 64. line 4386 "rejects malformed streamed tool input ordering".