fix(new-nav): remove deprecated checkRunningStatusClosed query and fix service table re-rendering issue#2625
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## new-navigation #2625 +/- ##
=================================================
Coverage ? 45.40%
=================================================
Files ? 1094
Lines ? 22968
Branches ? 6770
=================================================
Hits ? 10429
Misses ? 10663
Partials ? 1876
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
This PR removes the deprecated “checkRunningStatusClosed” React Query keys/hooks that were fed by WebSocket close events, and adjusts status WebSocket scoping + service table memoization to reduce unnecessary re-renders and fix failing tests.
Changes:
- Removed deprecated
checkRunningStatusClosedquery keys and feature hooks (services + environments) and corresponding consumer logic. - Scoped status WebSocket listeners to reduce unnecessary connections during environment loading, and stabilized service table column definitions to prevent re-render churn.
- Updated
SelectCommitModalunit test to be timezone/relative-time stable and refreshed snapshots.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| libs/shared/util-web-sockets/src/lib/use-status-web-sockets/use-status-web-sockets.ts | Removes the onClose “closed status” cache update for NotFound closes. |
| libs/pages/layout/src/lib/feature/layout/layout.tsx | Memoizes/scopes clusters used for status WebSocket listeners to avoid opening many sockets during env loading. |
| libs/domains/services/feature/src/lib/service-list/service-list.tsx | Moves createColumnHelper into the columns useMemo to stabilize columns and reduce table re-renders; adjusts selection click handling. |
| libs/domains/services/feature/src/lib/select-commit-modal/select-commit-modal.spec.tsx | Mocks date utilities to make snapshots stable across timezones/runs; updates mocked commit timestamps. |
| libs/domains/services/feature/src/lib/select-commit-modal/snapshots/select-commit-modal.spec.tsx.snap | Snapshot updates reflecting stabilized dates/text. |
| libs/domains/services/feature/src/lib/hooks/use-services/use-services.ts | Minor refactor of memoized mapping for service status decoration. |
| libs/domains/services/feature/src/lib/hooks/use-check-running-status-closed/use-check-running-status-closed.ts | Deletes deprecated hook. |
| libs/domains/services/data-access/src/lib/domains-services-data-access.ts | Removes deprecated checkRunningStatusClosed query key. |
| libs/domains/environments/feature/src/lib/hooks/use-check-running-status-closed/use-check-running-status-closed.ts | Deletes deprecated hook. |
| libs/domains/environments/feature/src/lib/environment-state-chip/environment-state-chip.tsx | Removes “closed status” fallback logic from the running state chip. |
| libs/domains/environments/data-access/src/lib/domains-environments-data-access.ts | Removes deprecated checkRunningStatusClosed query key. |
| tests/mocks.ts | Tightens Auth0 mock typing (children + HOC component type). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
This PR:
new-navigationbranchScreenshots / Recordings
📺 https://www.loom.com/share/759a0dc1ef3f4571872f25bc4ac48f87