fix: detect claude arrow-glyph question prompts
This commit is contained in:
parent
b695d7cbc0
commit
719dff6d3c
|
|
@ -69,6 +69,22 @@ herdr update
|
|||
|
||||
`herdr update` is for installs managed by Herdr's own installer. Homebrew and Nix installs update through `brew upgrade herdr` or your Nix workflow, then use the same stop-and-run-again flow if a session is still running the old server. Direct installs can opt into development preview builds with `herdr channel set preview` and return to stable with `herdr channel set stable`. See [install docs](https://herdr.dev/docs/install/) and [session state docs](https://herdr.dev/docs/session-state/) for the full update, restart, restore, and handoff matrix.
|
||||
|
||||
Herdr uses the stable update channel by default. To test preview builds from `master` before the next stable release:
|
||||
|
||||
```bash
|
||||
herdr channel set preview
|
||||
herdr update
|
||||
```
|
||||
|
||||
To return to stable:
|
||||
|
||||
```bash
|
||||
herdr channel set stable
|
||||
herdr update
|
||||
```
|
||||
|
||||
Preview is only for direct installs managed by Herdr's updater. Homebrew and Nix stay on stable and update through their package managers.
|
||||
|
||||
## how it compares
|
||||
|
||||
| | tmux | gui managers | herdr |
|
||||
|
|
|
|||
|
|
@ -99,7 +99,10 @@ fn has_live_blocked_form(content: &str) -> bool {
|
|||
lower.contains("enter to select")
|
||||
&& lower.contains("esc to cancel")
|
||||
&& (lower.contains("tab/arrow keys to navigate")
|
||||
|| lower.contains("arrow keys to navigate"))
|
||||
|| lower.contains("arrow keys to navigate")
|
||||
|| lower.contains("arrows to navigate")
|
||||
|| lower.contains("↑/↓ to navigate")
|
||||
|| lower.contains("↑↓ to navigate"))
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -999,6 +999,16 @@ mod tests {
|
|||
assert!(!detection.visible_idle);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn claude_question_form_with_arrow_glyph_footer_is_visible_blocker() {
|
||||
let screen = "❯ this is a test can you use question otol to ask questiosns\n\n Thought for 16s (ctrl+o to expand)\n─────────────────────────────────────────────────────────────────────────────────────────\n ☐ Test type\n\nWhich kind of test question should I ask you next?\n\n❯ 1. Single choice\n Ask one multiple-choice question.\n 2. Multi choice\n Ask one question that allows several answers.\n 3. With preview\n Ask with side-by-side previews.\n 4. Type something.\n─────────────────────────────────────────────────────────────────────────────────────────\n 5. Chat about this\n\nEnter to select · ↑/↓ to navigate · Esc to cancel";
|
||||
let detection = detect_agent(Some(Agent::Claude), screen);
|
||||
|
||||
assert_eq!(detection.state, AgentState::Blocked);
|
||||
assert!(detection.visible_blocker);
|
||||
assert!(!detection.visible_idle);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn claude_question_form_selected_bottom_is_visible_blocker() {
|
||||
let screen = "❯ ask again\n─────────────────────────────────────────────────────────────────────────────────────────\n← ☐ Subject ☐ Tone ✔ Submit →\n\nWhat should I ask you about?\n\n 1. Today\n Your current plan or priority.\n 2. Project\n A codebase, feature, bug, or PR.\n 3. Preference\n How you want me to work with you.\n 4. Random\n A casual question with no work context.\n 5. Type something.\n─────────────────────────────────────────────────────────────────────────────────────────\n❯ 6. Chat about this\n\nEnter to select · Tab/Arrow keys to navigate · ctrl+g to edit in Zed · Esc to cancel";
|
||||
|
|
|
|||
Loading…
Reference in New Issue