Repository navigation
[2.0] Backport #38410 - #38960
[2.0] Backport #38410#38960ShaileshParmar11 wants to merge 1 commit into
Conversation
❌ PR checklist incompleteThis PR cannot be merged until the following are addressed on its linked issue:
The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically. Maintainers can bypass this check by adding the |
Code Review ✅ Approved 🟡 Medium riskClearing Incident Manager filters now removes pagination cursors, so users return to the unfiltered result set instead of remaining on an invalid page. Fixes the Incident Manager so clicking Clear all on a later page of a filtered list drops the stale VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
Backport of #38410 (
295f502d4ae) to2.0.What it fixes
In the Incident Manager, clicking Clear all on a later page of a filtered list kept
currentPage,cursorTypeandcursorValuein the URL, so the user stayed on page N of a different (unfiltered) result set.Why this is a hand port, not a clean cherry-pick
2.0's hook differs from main:clearAllFilterscalledupdateFilters, which spreads the cleared filters over the whole current query, so the paging params survived. The cherry-pick conflicted, and2.0'sIncidentManager.test.tsxhas no Clear all test to extend. So this PR:clearAllFiltersinuseIncidentFilters.tsto navigate withomit(allParams, [...filter params, 'currentPage', 'cursorType', 'cursorValue']), the same shape asclearFilterson main. It still clears the assignee owner refs. It keepskey/titleas2.0did before, so the only behaviour change is the dropped paging params.useIncidentFilters.test.tsthat asserts the resulting query is exactlyother=z&pageSize=15. The test fails on unfixed2.0(receivedcurrentPage=5&cursorType=after&cursorValue=foo&other=z&pageSize=15).Related
2.0, not on it. The two change different functions;git mergeof the two branches is conflict-free in either order.Tests (local, Node 22, 2.0 dependencies)
npx jest src/components/IncidentManager: 8 suites, 103/103 passed🤖 Generated with Claude Code