Skip to content

Accept both issue ID formats in issue: and issue.id: filters #130940

Description

@sentry-junior

Event search has two filters for the same thing, and each accepts only one issue ID format:

  • issue: accepts only qualified short IDs (PROJECT-123). A numeric group ID such as issue:4567 fails the short-ID lookup and returns a 400: Issue IDs do not exist: ['4567']. This happens in the Discover/errors dataset (_issue_filter_converter in src/sentry/search/events/datasets/discover.py) and in the EAP occurrences dataset (_init_issue_short_id_cache in src/sentry/search/eap/resolver.py).
  • issue.id: is a numeric key in the search parser (default_config in src/sentry/api/event_search.py), so issue.id:PROJECT-123 fails to parse with Invalid number.
  • Other APIs return numeric issue IDs, so API and MCP clients that pass them to issue: get a 400. The Sentry MCP server now rewrites numeric issue: filters to issue.id: on the client to work around this (fix(mcp): Accept numeric issue IDs in error searches toolkit#2204).

Proposal from @dcramer: issue: should accept every format, and issue.id: should accept short IDs. There is no value in keeping the two split.

--

View Session [Sentry]

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions