“Invalid choice value”: name the valid values in the error #21
skudr opened 3 weeks ago

Current behavior (tod 4.3.4). When issue create, issue edit or issue change-state gets --field Type=Taks, the error says “Invalid choice value” and nothing else. The agent has to call tod issue get-valid-fields, find the field and retry.

Proposal. Include the valid choices of the offending field in the error message, for example Invalid choice value "Taks" for field "Type"; valid values: Bug, Task, Improvement.

Why. Anthropic’s guidance for agent tools recommends exactly this: “prompt-engineer your error responses to clearly communicate specific and actionable improvements, rather than opaque error codes” (“Writing effective tools for agents”, anthropic.com/engineering/writing-tools-for-agents). It turns one failed call plus two recovery calls into a single retry.

1/1
Type
Enhancement
Priority
Minor
Assignee
Labels
No labels
Issue Votes (0)
Watchers (2)
Reference
TOD-21
Please wait...
Connection lost or session expired, reload to recover
Page is in error, reload to recover