Add feedback reminder for CodeRabbit#4932
Conversation
Signed-off-by: Tomoyuki Morita <moritato@amazon.com>
📝 WalkthroughSummary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings. WalkthroughA new GitHub Actions workflow is added that automatically appends a feedback prompt to code review comments created by coderabbitai[bot]. The workflow triggers on pull request review comments and invites users to leave emoji reactions to gauge effectiveness. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Suggested reviewers
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
.github/workflows/coderabbit-feedback.yml (1)
12-28: Add error handling and logging to the script.The script lacks error handling for the API call, and there's no logging to aid debugging if the update fails. If the comment update encounters an error (e.g., rate limit, permission issue), the workflow will silently fail without useful feedback.
Apply this diff to add error handling and logging:
- uses: actions/github-script@v8 with: github-token: ${{ secrets.GITHUB_TOKEN }} script: | const comment = context.payload.comment; const originalBody = comment.body; const feedbackMessage = "\n\n<sub>👋 Leave emoji reaction (👍/👎) to track effectiveness of CodeRabbit.</sub>"; // Only add the message if it's not already there if (!originalBody.includes(feedbackMessage)) { + try { await github.rest.pulls.updateReviewComment({ owner: context.repo.owner, repo: context.repo.repo, comment_id: comment.id, body: originalBody + feedbackMessage }); + console.log(`Successfully appended feedback message to comment ${comment.id}`); + } catch (error) { + console.error(`Failed to append feedback message: ${error.message}`); + throw error; + } + } else { + console.log(`Feedback message already present in comment ${comment.id}`); }This ensures visibility into both successes and failures.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
.github/workflows/coderabbit-feedback.yml(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (28)
- GitHub Check: security-it-linux (25)
- GitHub Check: security-it-linux (21)
- GitHub Check: build-linux (21, doc)
- GitHub Check: build-linux (25, integration)
- GitHub Check: build-linux (21, unit)
- GitHub Check: build-linux (25, unit)
- GitHub Check: build-linux (25, doc)
- GitHub Check: build-linux (21, integration)
- GitHub Check: bwc-tests-rolling-upgrade (25)
- GitHub Check: bwc-tests-full-restart (21)
- GitHub Check: bwc-tests-rolling-upgrade (21)
- GitHub Check: bwc-tests-full-restart (25)
- GitHub Check: security-it-windows-macos (windows-latest, 21)
- GitHub Check: security-it-windows-macos (macos-14, 21)
- GitHub Check: security-it-windows-macos (windows-latest, 25)
- GitHub Check: security-it-windows-macos (macos-14, 25)
- GitHub Check: build-windows-macos (macos-14, 21, integration)
- GitHub Check: build-windows-macos (windows-latest, 25, -PbuildPlatform=windows, integration)
- GitHub Check: build-windows-macos (windows-latest, 21, -PbuildPlatform=windows, integration)
- GitHub Check: build-windows-macos (macos-14, 25, integration)
- GitHub Check: build-windows-macos (windows-latest, 21, -PbuildPlatform=windows, unit)
- GitHub Check: build-windows-macos (macos-14, 25, unit)
- GitHub Check: build-windows-macos (macos-14, 21, unit)
- GitHub Check: build-windows-macos (macos-14, 21, doc)
- GitHub Check: build-windows-macos (macos-14, 25, doc)
- GitHub Check: build-windows-macos (windows-latest, 25, -PbuildPlatform=windows, unit)
- GitHub Check: Update draft release notes
- GitHub Check: CodeQL-Scan (java)
🔇 Additional comments (1)
.github/workflows/coderabbit-feedback.yml (1)
1-10: LGTM on the workflow structure.The trigger configuration, permissions, and job filtering look appropriate for this use case.
dai-chen
left a comment
There was a problem hiding this comment.
Just wonder is this doable in Coderabbit config? Just feel this workflow is very specific for this small task.
|
@ykmr1224 Also wondering is this knowledge base feature available to us? Instead of manual analysis, can we give feedback to Coderabbit directly? https://docs.coderabbit.ai/integrations/knowledge-base |
Coderabbit don't have configuration for this kind of customization so far.
It is enabled and doable, but that relies on each developer giving appropriate feedback. |
I agree. Either the knowledge base can separate team and personal preference, or we give permission to a small group. We can discuss offline. I'm just thinking we can maintain a single source of coding guidance, team knowledge between local Dev agent and this Review agent. Thanks! cc: @penghuo |
Description
👋 Leave emoji reaction (👍/👎) to track effectiveness of CodeRabbit.Related Issues
n/a
Check List
--signoffor-s.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.