Skip to content

Conversation

@souky-byte
Copy link
Owner

@souky-byte souky-byte commented Jan 2, 2026

Summary

  • Auto-start AI Review execution when development phase completes
  • New Problems tab in task detail showing AI Review findings with accordion UI
  • Findings grouped by severity with individual and group selection
  • Fix selected, Fix all, and Skip actions for handling findings

Test plan

  • Verify AI Review automatically runs after implementation completes
  • Check Problems tab appears only when findings exist
  • Test selecting/deselecting individual findings
  • Test group selection by severity
  • Verify Fix selected/Fix all/Skip actions work correctly

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Automatic task execution triggered during the review workflow
    • New Problems tab displays AI-identified findings grouped by severity level
    • Bulk actions to fix or skip findings with success feedback
    • Per-finding selection and expandable details showing file locations

✏️ Tip: You can customize this high-level summary in your review settings.

Implement auto-execution of AI Review when development completes and add a new Problems tab in task detail panel to display AI Review findings with selection and action capabilities. Includes accordion-style UI for severity-grouped findings, individual and group selection, and Fix/Skip actions.

🤖 Generated with Claude Code

Co-Authored-By: Claude Haiku 4.5 <[email protected]>
@coderabbitai
Copy link

coderabbitai bot commented Jan 2, 2026

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Walkthrough

This pull request introduces an auto-execution workflow for tasks and a new ProblemsTab component for displaying AI review findings. The auto-execute feature triggers task execution when certain events occur, while ProblemsTab enables users to view, filter, and manage code review findings grouped by severity with bulk actions.

Changes

Cohort / File(s) Summary
Auto-execute Flow
frontend/src/App.tsx, frontend/src/hooks/useEventStream.ts
Added useExecuteTask hook integration in App.tsx and introduced optional onAutoExecute callback to UseEventStreamOptions in useEventStream.ts. The hook now triggers auto-execution when tasks transition from in_progress to ai_review status.
Problems Tab Component
frontend/src/components/task-detail/ProblemsTab.tsx, frontend/src/components/task-detail/TaskDetailPanel.tsx
Introduced new ProblemsTab component with findings display, severity grouping (error/warning/info), per-item and bulk selection, and actions (Fix selected/all, Skip). TaskDetailPanel now fetches findings via useGetTaskFindings hook and conditionally renders the Problems tab with badge.
UI Components
frontend/src/components/ui/checkbox.tsx, frontend/src/components/ui/icon.tsx
Added new Checkbox component with indeterminate state support and CheckboxProps interface. Extended icon.tsx with new icon names (info, alert-circle, alert-triangle, minus) and their Lucide icon mappings.

Sequence Diagram

sequenceDiagram
    participant App
    participant useEventStream
    participant SSEEvent as SSE Event
    participant useExecuteTask
    participant API as Tasks API

    App->>useEventStream: Pass onAutoExecute handler
    SSEEvent->>useEventStream: Task status changed (in_progress → ai_review)
    useEventStream->>useEventStream: Check status transition
    alt Status is ai_review
        useEventStream->>App: Trigger onAutoExecute(taskId)
        App->>useExecuteTask: Call executeTask.mutate({ id: taskId })
        useExecuteTask->>API: POST /tasks/{taskId}/execute
        API-->>useExecuteTask: Success
        useExecuteTask-->>App: Task executed
    end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Poem

🐰 A task shall execute when the moment is right,
And findings are grouped for the reviewer's sight—
With checkboxes checked and severity clear,
Problems cascade in colors austere.
The rabbit hops onward, automation near! ✨

✨ Finishing touches
  • 📝 Generate docstrings

📜 Recent review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bea6d78 and 52163ff.

⛔ Files ignored due to path filters (1)
  • frontend/package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (6)
  • frontend/src/App.tsx
  • frontend/src/components/task-detail/ProblemsTab.tsx
  • frontend/src/components/task-detail/TaskDetailPanel.tsx
  • frontend/src/components/ui/checkbox.tsx
  • frontend/src/components/ui/icon.tsx
  • frontend/src/hooks/useEventStream.ts

Comment @coderabbitai help to get the list of available commands and usage tips.

@souky-byte souky-byte merged commit 90f00f5 into master Jan 2, 2026
1 of 2 checks passed
@souky-byte souky-byte deleted the souky-byte/ai-review-problems-ui branch January 2, 2026 19:26
@greptile-apps
Copy link

greptile-apps bot commented Jan 2, 2026

Greptile Summary

This PR implements automatic AI Review execution when development completes and adds a new Problems tab for managing review findings.

Key Changes:

  • Auto-start: AI Review automatically executes when task transitions from in_progress to ai_review status via event stream handling
  • Problems tab: New UI for viewing findings grouped by severity (error/warning/info) with accordion interface
  • Finding management: Individual and group selection with Fix selected, Fix all, and Skip actions
  • UI components: New Checkbox component with indeterminate state support for group selection

Issues Found:

  • The skipFindings mutation doesn't invalidate the findings query cache, which could leave stale findings displayed in the UI after skipping

Confidence Score: 4/5

  • Safe to merge after fixing the query invalidation issue
  • Implementation is well-structured with proper React patterns (memoization, query invalidation). One logical issue found with missing cache invalidation in skipFindings that could cause stale UI state
  • frontend/src/components/task-detail/ProblemsTab.tsx needs the skipFindings cache invalidation fix

Important Files Changed

Filename Overview
frontend/src/hooks/useEventStream.ts Added auto-execute callback for AI Review phase transitions, properly memoized with useRef
frontend/src/App.tsx Integrated auto-execute handler for AI Review with proper memoization using useCallback
frontend/src/components/task-detail/TaskDetailPanel.tsx Added Problems tab with conditional rendering based on findings availability
frontend/src/components/task-detail/ProblemsTab.tsx New component for displaying and managing review findings with selection and actions; missing findings query invalidation in skipFindings

Sequence Diagram

sequenceDiagram
    participant User
    participant TaskDetailPanel
    participant Backend
    participant EventStream
    participant App
    participant ProblemsTab

    Note over User,ProblemsTab: Development Phase Completes
    Backend->>EventStream: task.status_changed (in_progress → ai_review)
    EventStream->>App: onAutoExecute(taskId)
    App->>Backend: POST /api/tasks/{id}/execute
    Backend-->>App: 202 Accepted
    
    Note over Backend: AI Review Executes
    Backend->>EventStream: session.started
    Backend->>EventStream: session.ended (success)
    Backend->>EventStream: task.status_changed (ai_review → review)
    
    Note over User,ProblemsTab: User Opens Task Detail
    TaskDetailPanel->>Backend: GET /api/tasks/{id}/findings
    Backend-->>TaskDetailPanel: findings data
    TaskDetailPanel->>TaskDetailPanel: hasFindings = true
    TaskDetailPanel->>ProblemsTab: render with findings
    
    Note over User,ProblemsTab: User Interacts with Findings
    User->>ProblemsTab: Select findings
    User->>ProblemsTab: Click "Fix selected"
    ProblemsTab->>Backend: POST /api/tasks/{id}/fix-findings
    Backend-->>ProblemsTab: 202 Accepted
    ProblemsTab->>ProblemsTab: Invalidate queries & clear selection
    
    alt User skips findings
        User->>ProblemsTab: Click "Skip"
        ProblemsTab->>Backend: POST /api/tasks/{id}/skip-findings
        Backend-->>ProblemsTab: 200 OK
        ProblemsTab->>ProblemsTab: Invalidate task query only
    end
Loading

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

6 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

Comment on lines +83 to +93
const skipFindings = useSkipFindings({
mutation: {
onSuccess: () => {
void queryClient.invalidateQueries({ queryKey: getListTasksQueryKey() });
toast.success("Findings skipped, task moved to review");
},
onError: () => {
toast.error("Failed to skip findings");
},
},
});
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

logic: missing query invalidation - should invalidate findings query like fixFindings does on line 73, otherwise UI may show stale findings after skip

Prompt To Fix With AI
This is a comment left during a code review.
Path: frontend/src/components/task-detail/ProblemsTab.tsx
Line: 83:93

Comment:
**logic:** missing query invalidation - should invalidate findings query like `fixFindings` does on line 73, otherwise UI may show stale findings after skip

How can I resolve this? If you propose a fix, please make it concise.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant