Repository navigation
Commit 6b5c859
perf(cli): Skip adjacent-event lookups on project event details (#1712)
`@sentry/api` 0.423.0, which #1713 bumped on main, defaults
`collapse=adjacentEvents` on `getOrganizationIssueEvent` and
`getProjectEvent` (getsentry/sentry-api-schema#112 and #113). With it,
Sentry skips the next/previous-event lookups. Nothing in the CLI reads
`nextEventID` or `previousEventID`.
Requests that change:
- CLI `getEvent()` → `projects/{org}/{project}/events/{event_id}/`. This
is the explicit event-ID path in `sentry event view`, and it now sends
the param through the SDK default. #1705 skipped it because the project
endpoint didn't support `collapse` yet. getsentry/sentry#129123 added
that support. Until it deploys, Sentry ignores the unknown value.
- CLI `getLatestEvent()` keeps sending the param, but through the SDK
default now. The explicit `collapse` query #1705 added there is gone,
along with its URL assertion, since that would only test the SDK
default.
A tier test confirms that project event URLs with the param stay
`volatile`.
### Behavior notes
- Once getsentry/sentry#129123 deploys, `sentry event view
<org>/<project> <event-id> --json` will return
`nextEventID`/`previousEventID` as null. Issue latest-event lookups
already behave this way after #1705.
- Response-cache keys for project event URLs change, so existing entries
miss once and then fill again.
<!-- junior-session-footer:start -->
<!-- junior-conversation-id:agent%3Aea5efd697aa911af7986f685a5952441 -->
--
[View Junior Session in
Sentry](https://sentry.sentry.io/explore/conversations/agent%3Aea5efd697aa911af7986f685a5952441/?project=4510944073809921)
<!-- junior-session-footer:end -->
---------
Co-authored-by: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com>
Co-authored-by: BYK <burak.kaya@sentry.io>1 parent 4a902fc commit 6b5c859
4 files changed
Lines changed: 11 additions & 14 deletions
File tree
- packages
- cli
- src/lib/api
- test/lib
- toolkit-core/src/response-cache
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | 9 | | |
11 | 10 | | |
12 | 11 | | |
| |||
44 | 43 | | |
45 | 44 | | |
46 | 45 | | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | 46 | | |
55 | 47 | | |
56 | 48 | | |
| |||
59 | 51 | | |
60 | 52 | | |
61 | 53 | | |
62 | | - | |
63 | 54 | | |
64 | 55 | | |
65 | 56 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1006 | 1006 | | |
1007 | 1007 | | |
1008 | 1008 | | |
1009 | | - | |
1010 | | - | |
1011 | | - | |
1012 | 1009 | | |
1013 | 1010 | | |
1014 | 1011 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
37 | 45 | | |
38 | 46 | | |
39 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
53 | | - | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
0 commit comments