You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
search_errors agent rewrites issue short IDs in structured queries #2443
A structured search_errors query such as issue:PROJ-2B3 still goes through the embedded agent, and the agent's query runs as-is. In the reported session the agent dropped the last character of a valid short ID (issue:PROJ-2B3 became issue:PROJ-2B; placeholder IDs here), and Sentry answered 400 Issue IDs do not exist. The caller worked around it with the numeric issue ID.
Reports: 2
MCP-SERVER-GS9 (2026-11-18, search_errors): a valid short ID came back truncated by one character, HTTP 400.
MCP-SERVER-GSX (2026-11-20, same client and task, kind=broken, impact=worked_around): asks to preserve full short IDs in translation or resolve them to numeric group IDs.
Verified from the sampled search_errors span (server 0.42.0):
Tool args: a single issue:<short id> query, explicit aggregate fields, period=24h, no sort.
callEmbeddedAgent received the full short ID in User query: and returned the query with the last character missing, with an explanation claiming it kept the issue filter.
validateSearch passed because the validate endpoint doesn't check the errors dataset; the following GET /events/?dataset=errors returned the 400 that the tool passed on.
Errors isn't a trace-item dataset, so shouldTrustStructuredTraceSearch is false and canRunWithoutAgent never applies (search.ts:828-835); the agent always runs.
Only trace-item datasets get choosePreservingRepairedQuery's token check. For errors the agent's query is used unless isSemanticFilterDowngrade fires (search.ts:979-985), and that doesn't compare filter values.
normalizeNumericIssueFilters (utils.ts:319-341) only rewrites numeric IDs and isn't involved.
Related: #2379 (translator turns a bare UUID into trace:), #2212 (search_issues agent rewrites quoted phrases), #2139 (open: restores timestamp: bounds the agent drops, same code spot).
Activity
linear-code commentedon Nov 20, 2026
MCP-1264
fix(search-events): Keep issue filters the agent rewrites