fix(filters): use eq for --name so run/trace list name filtering works - #174
Open
Palash Shah (Palashio) wants to merge 1 commit into
Open
fix(filters): use eq for --name so run/trace list name filtering works#174Palash Shah (Palashio) wants to merge 1 commit into
Palash Shah (Palashio) wants to merge 1 commit into
Conversation
The --name flag on `run list` / `trace list` built its filter clause as
`search(name, …)`, but the backend runs/query validator rejects the SEARCH
comparator on the `name` attribute, so every `--name` query returned
HTTP 400 ("Comparison comparator=<Comparator.SEARCH> attribute='name' …
not accepted"). The flag is already documented as an exact-match filter,
so emit `eq(name, …)` instead — which the backend accepts and matches the
documented behavior.
Verified against a live project: `run list --name <name>` now returns the
matching runs (exact-match) instead of a 400.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Anirudh Sriram (asrira428)
approved these changes
Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
langsmith run list --name <x>(andtrace list --name <x>, which shares the same filter flags) returns HTTP 400 for any value:internal/cmd/filters.gobuilt the clause assearch(name, %q), but the backend runs/query validator does not accept theSEARCHcomparator on thenameattribute — onlyeq. So the--namefilter is completely non-functional. It also contradicts the flag's own help, which documents it as exact match.Fix
One-line comparator change: emit
eq(name, %q)instead ofsearch(name, %q).eqis both what the backend accepts and what the flag already promises. Value interpolation (%qquoting) is unchanged. Updated the two tests that asserted the oldsearch(name, …)output.Verification
go build ./...+go test ./internal/cmd/pass.run list --name ChatAnthropicWithOpenAIFallback→ HTTP 400ChatAnthropicWithOpenAIFallback(exact match, no 400)🤖 Generated with Claude Code