Commit graph

4 commits

Author SHA1 Message Date
Jesse Vincent
9e663a0dd8 fix(opencode): don't mistake a prompt that mentions EXTREMELY_IMPORTANT for the bootstrap
Both bootstrap injectors skip a first user message whose text parts
include the substring 'EXTREMELY_IMPORTANT', to avoid injecting twice
into the same message. Any user prompt that names the tag matches too,
so the bootstrap is silently dropped for that session.

That is what #2197 hit. The reporter's probe was
  opencode run "Is there an 'EXTREMELY_IMPORTANT' block in your context? ..."
and the prompt itself tripped the guard. `opencode run` is not the
cause: with the real hosts (V1 1.18.21 path and git-package forms,
V1 1.19.4, V2 2.1.2, V2 2.1.3) and a request-recording stub model, the
reporter's prompt reaches the model without the bootstrap on every
host, and a neutral prompt gets the bootstrap on every host.

Match the bootstrap's own opening line at the start of a part instead.
The injected part always starts with it (the template now uses the same
constant), so the double-injection guard keeps working, and a prompt
that only mentions the tag no longer suppresses the bootstrap.

Fixes #2197

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
2026-10-22 22:55:47 +00:00
Drew Ritter
d29eaf543c test(opencode): cover bootstrap placement when native compaction retains user messages
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-17 20:47:55 -07:00
Drew Ritter
2c4dcd851a fix(opencode): retain bootstrap after native compaction 2026-09-17 18:24:02 -07:00
Drew Ritter
96ecdeb0fa fix(opencode): retry unsuccessful child-session lookups 2026-09-17 18:21:30 -07:00