-
Notifications
You must be signed in to change notification settings - Fork 0
M3-T4: Vibe Kanban Review Watcher & Auto-Iteration (vibe-kanban) #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
98d286c
bc08e6c
98dfccc
2d06da1
9fe8cfc
7dd2d20
1492529
27dc05e
cf7a281
1a2d489
77cae28
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| /** | ||
| * Review routes - HTTP API for review watcher | ||
| * | ||
| * Provides endpoints to manage the review watcher service that monitors | ||
| * Vibe Kanban tasks in `inreview` status and auto-iterates on feedback. | ||
| */ | ||
|
|
||
| import { Router } from 'express'; | ||
| import type { ReviewWatcherService } from '../../services/review-watcher.js'; | ||
| import { createPendingReviewHandler } from './routes/pending-review.js'; | ||
|
|
||
| export function createReviewRoutes(reviewWatcherService: ReviewWatcherService): Router { | ||
| const router = Router(); | ||
|
|
||
| router.get('/pending', createPendingReviewHandler(reviewWatcherService)); | ||
|
|
||
| return router; | ||
|
Comment on lines
+12
to
+17
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: # Search for submit endpoint in review routes
rg -n "submit" --type=ts apps/server/src/routes/review/
# Check the complete contents of the review routes index file
cat -n apps/server/src/routes/review/index.ts
# Search for any createSubmitReviewHandler or similar
rg -n "createSubmitReviewHandler|/submit" --type=ts apps/server/src/Repository: 0xtsotsi/DevFlow Length of output: 789 🏁 Script executed: # Search entire apps/server for /submit or submit handler
rg -n "/submit|submitReview|SubmitReview" --type=ts apps/server/
# Search for any PR description or documentation
fd -t f "README|DESCRIPTION|.md" apps/server/src/routes/review/ 2>/dev/null || echo "No markdown files found"
# Check if there's a pending-review handler to understand pattern
cat -n apps/server/src/routes/review/routes/pending-review.ts 2>/dev/null || echo "pending-review file not found"
# List all files in review routes directory
find apps/server/src/routes/review/ -type f 2>/dev/nullRepository: 0xtsotsi/DevFlow Length of output: 1631 Implement missing The 🤖 Prompt for AI Agents |
||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| /** | ||
| * GET /review/pending endpoint - List pending reviews | ||
| * | ||
| * Returns all tasks currently being watched by the review watcher service. | ||
| * This includes tasks in `inreview` status with their comment counts and iteration status. | ||
| */ | ||
|
|
||
| import type { Request, Response } from 'express'; | ||
| import type { ReviewWatcherService } from '../../../services/review-watcher.js'; | ||
| import { createLogger } from '@automaker/utils'; | ||
|
|
||
| const logger = createLogger('Review'); | ||
|
|
||
| export function createPendingReviewHandler(reviewWatcherService: ReviewWatcherService) { | ||
| return async (req: Request, res: Response): Promise<void> => { | ||
| try { | ||
| const watchedTasks = reviewWatcherService.getWatchedTasks(); | ||
|
|
||
| logger.info(`[Review] Fetched ${watchedTasks.length} pending reviews`); | ||
|
|
||
| res.json({ | ||
| success: true, | ||
| data: { | ||
| tasks: watchedTasks, | ||
| count: watchedTasks.length, | ||
| isRunning: reviewWatcherService.getStatus().isRunning, | ||
| }, | ||
| }); | ||
| } catch (error) { | ||
| logger.error('[Review] Failed to fetch pending reviews:', error); | ||
| res.status(500).json({ | ||
| success: false, | ||
| error: error instanceof Error ? error.message : String(error), | ||
| }); | ||
| } | ||
| }; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: 0xtsotsi/DevFlow
Length of output: 102
🏁 Script executed:
Repository: 0xtsotsi/DevFlow
Length of output: 992
🏁 Script executed:
Repository: 0xtsotsi/DevFlow
Length of output: 42
🏁 Script executed:
# Read the ReviewWatcherService implementation to understand initialization cat -n apps/server/src/services/review-watcher.tsRepository: 0xtsotsi/DevFlow
Length of output: 20015
🏁 Script executed:
Repository: 0xtsotsi/DevFlow
Length of output: 42
🏁 Script executed:
Repository: 0xtsotsi/DevFlow
Length of output: 316
Add explicit
.start()call to ReviewWatcherService after instantiation.The
ReviewWatcherServicerequires an explicitstart()call to begin polling for in-review tasks. The constructor only initializes the service but does not start the polling loop. Without this call, the 30-second polling mechanism will never run. Addawait reviewWatcherService.start();in the async initialization block alongsideagentService.initialize().🤖 Prompt for AI Agents