GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(cli): keep the triage picker open after an invalid numbered choice by only21mil · Pull Request #42046 · pingdotgg/t3code

Conversation

@only21mil

@only21mil only21mil commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

At the t3 triage agent picker, an answer like 1.5 or 1x started the first agent instead of asking again. The picker read the answer with Number.parseInt, which stops at the first character that is not a digit.

The picker now takes a number only when the whole trimmed answer is one of the numbers it listed. Anything else falls through to the agent-id match (still case-insensitive) and then asks again, as before.

Scope

One line in apps/server/src/cli/triage.ts, plus a test. No issue: the bug is small and the steps below reproduce it.

Steps

An AI agent ran node apps/server/src/bin.ts triage --base-dir <scratch> on a real Linux PTY, with stub claude and codex scripts on PATH that only print started <name>. It answered 1.5, then 2 if asked again.

Before (main)After
Run triage with:
  [1] Claude Code
  [2] Codex
> 1.5
Starting Claude Code. It will ask what went wrong.

started claude
Run triage with:
  [1] Claude Code
  [2] Codex
> 1.5
Run triage with:
  [1] Claude Code
  [2] Codex
> 2
Starting Codex. It will ask what went wrong.

started codex

Tests

The new triage.test.ts cases drive the picker through terminal streams. 1.5, 1x, then 2 starts Codex after three questions. 2x, then CLAUDE starts Claude after two. On main both fail: one question is asked and an agent starts. An AI agent ran the file 3 times on Node 26.13.1 (10/10 passing), and vp run check:changed passes.

Not shown

The Windows desktop launcher console, and macOS.

Generated with Claude Opus 5.5 in T3 Code Nightly

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@only21mil
fix(cli): keep the triage picker open after an invalid numbered choice
ab21e7a
The t3 triage agent picker read answers with Number.parseInt, so 1.5 or 1x launched the first agent. It now takes a number only when the whole answer is one of the listed numbers, and asks again otherwise.
@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Nov 24, 2026
@coderabbitai

coderabbitai Bot commented Nov 24, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The agent picker now matches trimmed answers against exact one-based menu numbers or agent IDs without regard to case. Unmatched answers continue prompting. Tests cover valid choices, whitespace, case differences, and invalid answers.

Changes: Agent picker selection

Layer / File(s) Summary
Answer matching and picker integration
apps/server/src/cli/triage.ts, apps/server/src/cli/triage.test.ts
matchAgentAnswer matches trimmed answers to exact one-based menu numbers or case-insensitive agent IDs. pickAgent uses this helper and continues prompting when an answer does not match. Tests cover valid choices and invalid answers.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Suggested reviewers: motaghi, shethshlok

Merge Risk: Minimal · up to b2f36

The triage agent picker now rejects partial numeric answers such as 1.5 or 1x and asks again instead of starting the wrong agent. The change is small and covered by tests, so merge risk is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: the triage agent picker no longer accepts a partial numeric answer such as "1.5" or "1x" as a numbered choice, and it asks again. The diff matches this, since matchAgentAns…
Description check Passed The description follows the template sections (Problem, Change, Scope, Verification) in substance. It explains the bug: Number.parseInt accepts a leading digit and ignores the rest. It describes the f…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change: the triage agent picker no longer accepts a partial numeric answer such as "1.5" or "1x" as a numbered choice, and it asks again. The diff matches this, since matchAgentAnswer accepts a number only when the whole trimmed answer matches a listed number. The title is 70 characters and follows the conventional commit format the template suggests.

Full details: Description check

Explanation

The description follows the template sections (Problem, Change, Scope, Verification) in substance. It explains the bug: Number.parseInt accepts a leading digit and ignores the rest. It describes the fix as a whole-answer match. Scope gives a reason for having no linked issue. Verification gives reproduction steps on a real Linux PTY, before and after output, test results, and the checks not run (Windows launcher and macOS). The Problem and Change headings are not labeled as such, and the description does not link an issue or state whether a maintainer requested the PR. The template asks for a model and harness line, and the description includes one (Claude Opus 5.5 in T3 Code Nightly). These gaps are minor.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: pingdotgg/t3code
  • Branch: main
  • File: .coderabbit.config.ts
  • Commit: 2ced06e
  • Layers: Repository TS config
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a62ffe1a-145f-41c0-b82c-0e454418487d
Commits

Reviewing files that changed from the base of the PR and between ab21e7a and b2f369e.

Files selected for processing: 2

  • apps/server/src/cli/triage.test.ts
  • apps/server/src/cli/triage.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 5 remain after this review.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@juliusmarminge juliusmarminge added the takeover:in-progress A takeover lead is working on this PR label Nov 24, 2026
juliusmarminge and others added 2 commits November 24, 2026 09:34
@juliusmarminge
Merge remote-tracking branch 'origin/main' into fix/cli-triage-picker…
88a7daf
…-exact-number
@juliusmarminge @claude
test(cli): cover the triage picker's answer matching directly
b2f369e
Move answer matching into matchAgentAnswer and test it as a table, in place
of the test that swapped process.stdin/stdout and spied on readline.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions github-actions Bot added size:S 10-29 changed lines (additions + deletions). and removed size:XS 0-9 changed lines (additions + deletions). labels Nov 24, 2026
@juliusmarminge

juliusmarminge commented Nov 24, 2026

Copy link
Copy Markdown
Member

Evidence

Evidence: real CLI, Linux PTY (100×26), identical terminal rendering, fresh data for every invocation, only Claude and Codex stand-ins on PATH.

Four fresh runs per commit: 1.5 → 2; 2x → CLAUDE; 1x → 2; control abc → 2. Follow-up input was sent only when the picker remained open.

Before After
2ced06ef4a b2f369e394
Before: invalid numbered answers launch agents immediately After: invalid numbered answers redisplay the picker and valid follow-ups select the agent
Before recording After recording

Base reproduced all three invalid-number selections. Head kept asking and accepted the subsequent displayed number or case-insensitive agent ID. The abc control worked on both.

Reproduction and recording driver · Capture renderer · Before transcript · After transcript

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@juliusmarminge juliusmarminge added takeover:ready Takeover done; auto-lands when gates pass and removed takeover:in-progress A takeover lead is working on this PR labels Nov 24, 2026
@juliusmarminge
juliusmarminge merged commit fc91bfd into pingdotgg:main Nov 24, 2026
55 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@juliusmarminge juliusmarminge removed the takeover:ready Takeover done; auto-lands when gates pass label Nov 24, 2026
@patroza patroza mentioned this pull request Nov 24, 2026
Merge upstream main through 26f4c7550e7a patroza/t3code#673
Merged
@Yarden-zamir Yarden-zamir mentioned this pull request Nov 24, 2026
chore(sync): merge pingdotgg/t3code main Yarden-zamir/t3code#628
Merged
@coderabbitai coderabbitai Bot mentioned this pull request Nov 24, 2026
fix(cli): Ctrl+C or Ctrl+D at the t3 triage agent picker exits cleanly #42303
Merged
@only21mil only21mil mentioned this pull request Nov 26, 2026
fix(cli): t3 triage picker exits cleanly when its input closes #43449
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

size:S 10-29 changed lines (additions + deletions). vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@only21mil @juliusmarminge
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.