Skip to content

Prompt ux fix - #538

Merged
yogthos merged 2 commits into
mainfrom
prompt-ux-fix
Jun 29, 2026
Merged

Prompt ux fix#538
yogthos merged 2 commits into
mainfrom
prompt-ux-fix

Conversation

@yogthos

@yogthos yogthos commented Jun 29, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

Yogthos added 2 commits June 29, 2026 00:18
The memory, global-memory, and spec-store loads ran as unbounded
spawn_blocking calls, so a stuck or locked SQLite (NFS, a competing
writer, a corrupt WAL) would wedge agent construction indefinitely.
Since /prompt <name> rebuilds the agent on the sync path, that was a
real contributor to the "hang" symptom.

Wrap all three in spawn_blocking_with_timeout behind DB_LOAD_TIMEOUT
(5 s, looser than the 2 s git-branch bound since a first-run legacy
import can legitimately be slow). A timeout or join error collapses to
Err, matching the existing graceful-degradation path (the block is
omitted, agent still builds). Adds two unit tests for the helper.
`/prompt review please review X` silently dropped everything after the
name. It now switches the prompt and hands the trailing text to the
event loop via a DEFER_PROMPT_RUN sentinel, which launches a streamed
turn on that text -- the same control-flow channel as DEFER_COMPRESS
and DEFER_BTW, since slash handlers can't reach the loop's run slots.
The defer is gated on the prompt name resolving, so /prompt bogus ...
won't spuriously launch. Adds tests for the sentinel helper.
@yogthos
yogthos merged commit a70afd8 into main Jun 29, 2026
12 checks passed
yogthos pushed a commit that referenced this pull request Jun 30, 2026
PTY-backed !/!! bang commands (interactive gh/editors, vt100 in-place
render), /prompt <name> <text> runs the text, write_todo_list backed by
the issue board, clipboard copied tooltip, CI clippy gate, visible failed
MCP servers, stream retry on mid-tool-call chunk timeouts, and bounded DB
loads in agent construction. (#538, #539, #540, #541, #542, #544, #546, #547)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant