feat(ui): remove dead views and API functions for dropped v5 tables#204
Conversation
Delete all UI code tied to the observations and indexed_sessions tables dropped in v5 cleanup (US3 T024): Views deleted: - ObservationsView.vue, ObservationDetailView.vue - SessionsView.vue, SessionDetailView.vue - SearchView.vue Components deleted (old Sidebar cluster, unreachable from live App.vue): - Sidebar.vue, ProjectFilter.vue, SearchAnalytics.vue - TopObservations.vue, SystemHealthDetails.vue Composables deleted: - useObservation.ts, useSearch.ts, useSessions.ts Edited: - router/index.ts: remove /observations, /sessions, /search routes - AppSidebar.vue: remove observations, sessions, search nav items - composables/index.ts: remove dead barrel re-exports - utils/api.ts: remove ~270 lines of dead API functions and types Build: clean (vue-tsc + vite, 0 TS errors, 115 modules)
|
@coderabbitai review |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
💤 Files with no reviewable changes (1)
✅ Files skipped from review due to trivial changes (1)
WalkthroughЭто изменение удаляет множество страниц, компонентов, composables и API-экспортов, связанных с наблюдениями, поиском и сессиями, а также корректирует навигацию и индекс экспорта composables. Changes
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@ui/tsconfig.tsbuildinfo`:
- Line 1: The file ui/tsconfig.tsbuildinfo is a TypeScript build artifact and
must be excluded from VCS: add a rule *.tsbuildinfo to your .gitignore (or
append that pattern if .gitignore exists) and then remove the tracked file from
Git with git rm --cached ui/tsconfig.tsbuildinfo (commit the .gitignore change
and the removal) so it is no longer tracked; ensure future .tsbuildinfo files
are ignored.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 94f6c989-fb77-416c-964a-934c5cfc365b
📒 Files selected for processing (18)
ui/src/components/ProjectFilter.vueui/src/components/SearchAnalytics.vueui/src/components/Sidebar.vueui/src/components/SystemHealthDetails.vueui/src/components/TopObservations.vueui/src/components/layout/AppSidebar.vueui/src/composables/index.tsui/src/composables/useObservation.tsui/src/composables/useSearch.tsui/src/composables/useSessions.tsui/src/router/index.tsui/src/utils/api.tsui/src/views/ObservationDetailView.vueui/src/views/ObservationsView.vueui/src/views/SearchView.vueui/src/views/SessionDetailView.vueui/src/views/SessionsView.vueui/tsconfig.tsbuildinfo
💤 Files with no reviewable changes (16)
- ui/src/router/index.ts
- ui/src/components/ProjectFilter.vue
- ui/src/composables/index.ts
- ui/src/components/SystemHealthDetails.vue
- ui/src/composables/useSessions.ts
- ui/src/components/layout/AppSidebar.vue
- ui/src/views/SessionsView.vue
- ui/src/components/Sidebar.vue
- ui/src/composables/useSearch.ts
- ui/src/views/SearchView.vue
- ui/src/views/SessionDetailView.vue
- ui/src/views/ObservationsView.vue
- ui/src/views/ObservationDetailView.vue
- ui/src/composables/useObservation.ts
- ui/src/components/TopObservations.vue
- ui/src/components/SearchAnalytics.vue
There was a problem hiding this comment.
Code Review
This pull request performs a major cleanup by removing features related to observations, search, and sessions, including their associated views, components, and composables. The feedback identifies a critical issue where the removal of system health API functions breaks the health monitoring display in the sidebar. Additionally, it is noted that some observation-related code remains in the API utility, which should likely be removed for consistency if the underlying data structures have been dropped.
I am having trouble creating individual review comments. Click here to see my feedback.
ui/src/utils/api.ts (315-331)
The removal of fetchSystemHealth and its associated types (SystemHealth, ComponentHealth) appears to be premature. While the SystemHealthDetails.vue view was removed, the live AppSidebar.vue component (which is retained and edited in this PR) still uses the useHealth composable to display system status in its stats panel. Removing these API functions and types will break the health monitoring display in the sidebar.
ui/src/utils/api.ts (1)
The cleanup of observation-related code in this file seems incomplete. While several functions were removed, many others remain (e.g., fetchObservations, fetchObservationScore, submitObservationFeedback, updateObservationTags, and the Observation type itself). If the observations table has been completely dropped as stated in the PR description, these remaining functions and types are likely dead code and should also be removed to maintain consistency.
Add *.tsbuildinfo to .gitignore and untrack ui/tsconfig.tsbuildinfo. TypeScript build artifacts should not be version-controlled.
Bump daemon version v5.0.0 → v5.1.0, plugin 5.0.1 → 5.1.0. Since v5.0.1: - PR #202: dead-code sweep — removed Go references to dropped tables (-2861 lines) - PR #203: env var cleanup, auth-skip-local, dead features removal (-5862 lines) - PR #204: dead UI views and API functions removal (-4065 lines) - PR #205: Activity Timeline + observation UI cleanup (-2784 lines) Total: ~15,500 lines of dead code removed post-v5.0.0.
Summary
Removes all Vue dashboard UI code that referenced the
observationsandindexed_sessions(sdk_sessions) tables dropped in the v5 cleanup (US3 T024 / PR #202).Changes
Views deleted (5):
ObservationsView.vue,ObservationDetailView.vueSessionsView.vue,SessionDetailView.vueSearchView.vueComponents deleted (5 — old unreachable Sidebar cluster):
Sidebar.vue(old sidebar, never used by live App.vue which uses AppSidebar.vue)ProjectFilter.vue,SearchAnalytics.vue,TopObservations.vue,SystemHealthDetails.vueComposables deleted (3):
useObservation.ts,useSearch.ts,useSessions.tsEdited (4):
router/index.ts— remove routes for/observations,/observations/:id,/sessions,/sessions/:id,/searchAppSidebar.vue— remove Observations, Sessions, Search nav itemscomposables/index.ts— remove dead barrel re-exports for deleted composablesutils/api.ts— remove ~270 lines of dead API functions, types, and helpers (fetchObservationsPaginated,fetchObservationById,updateObservation,archiveObservations,searchObservations,searchDecisions, all search analytics functions, sessions index section,fetchTopObservations,fetchMostRetrievedObservations,SystemHealthinterface,ComponentHealthinterface,fetchSystemHealth,putJsonhelper)Verification
Build clean:
vue-tsc -b && vite build→✓ 115 modules transformed, ✓ built in 2.87s, 0 TypeScript errors.Summary by CodeRabbit