PY-46: GitHub Integration Nacharbeiten#27
Conversation
✅ Deploy Preview for pno-project-y ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughDetects CodeRabbit bot review digests, summarizes actionable/addressed findings, optionally collapses addressed segments in rendered markdown, adds a "needs action" filter and bot-summary UI in the review feed, and styles addressed-finding blocks. ChangesBot Review Digest Detection & Conditional Collapsing
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes 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 docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/components/git/TaskPullRequestReviewFeed.tsx`:
- Around line 139-149: The filter toggle is hidden when
botDigestRollup.digestCount is 0, which prevents users from turning off an
active needsActionOnly filter; change the render condition so the Button (the
"Needs action only" toggle using setNeedsActionOnly and reading needsActionOnly)
is shown when botDigestRollup?.digestCount > 0 OR when needsActionOnly is true.
Keep the existing props (variant, size, className, onClick) and behavior the
same; only update the conditional around the Button to use
(botDigestRollup?.digestCount > 0 || needsActionOnly).
In `@src/lib/git/bot-review-comment-summary.ts`:
- Around line 47-54: The fallback computation for openCount incorrectly
short-circuits to 0 whenever addressedCount > 0 and ignores markers like
"Committable suggestion", so unresolved findings get misclassified; update the
ternary in bot-review-comment-summary.ts so that when actionableCount is null
you first derive a baseSuggestedCount from the comment body (e.g., /Committable
suggestion/i or /Potential issue/i → 1 else 0) and then compute openCount as
Math.max(0, baseSuggestedCount - addressedCount) (referencing the variables
openCount, actionableCount, addressedCount, and body) instead of returning 0
immediately when addressedCount > 0.
In `@src/lib/git/preprocess-github-markdown.ts`:
- Around line 29-31: The current early return in preprocessGithubMarkdown that
checks "if (blocks.length <= 1) { return isAddressedSegment(body) ?
wrapAddressedSegment(body) : body; }" can collapse the entire digest when block
boundaries aren't detected; change this to simply return the original body when
blocks.length <= 1 (i.e., "return body") so we don't wrap the whole message
based on a single addressed marker. Locate the check around "blocks.length <= 1"
in preprocess-github-markdown.ts (functions/identifiers: blocks,
isAddressedSegment, wrapAddressedSegment, body) and replace the conditional wrap
with a plain fallback returning body.
🪄 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: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: a040b489-dace-492c-a1b2-0b30a571efb4
📒 Files selected for processing (6)
src/components/git/GitHubMarkdownBody.tsxsrc/components/git/PrReviewFeedItem.tsxsrc/components/git/TaskPullRequestReviewFeed.tsxsrc/components/git/github-markdown-sanitize.tssrc/lib/git/bot-review-comment-summary.tssrc/lib/git/preprocess-github-markdown.ts
There was a problem hiding this comment.
♻️ Duplicate comments (1)
src/lib/git/bot-review-comment-summary.ts (1)
57-62:⚠️ Potential issue | 🟠 Major | ⚡ Quick winCount unresolved fallback signals instead of using a boolean.
Line 57 sets a 1/0 fallback, so digests without an actionable header can undercount remaining findings (and potentially clear
needsActiontoo early) when multiple unresolved markers exist.💡 Proposed fix
- const baseSuggestedCount = - /Committable suggestion|Potential issue/i.test(body) ? 1 : 0; + const baseSuggestedCount = ( + body.match(/Committable suggestion|Potential issue/gi) ?? [] + ).length;🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/lib/git/bot-review-comment-summary.ts` around lines 57 - 62, The current fallback uses a boolean 1/0 via baseSuggestedCount which undercounts when multiple unresolved markers exist; update baseSuggestedCount to count all occurrences of the fallback signals (e.g., run a global regex match against body for /Committable suggestion|Potential issue/gi and use the match length or 0) and keep openCount logic the same (openCount = actionableCount != null ? Math.max(0, actionableCount - addressedCount) : Math.max(0, baseSuggestedCount - addressedCount)), referencing baseSuggestedCount, actionableCount, addressedCount and body to locate and replace the 1/0 fallback with the match count.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Duplicate comments:
In `@src/lib/git/bot-review-comment-summary.ts`:
- Around line 57-62: The current fallback uses a boolean 1/0 via
baseSuggestedCount which undercounts when multiple unresolved markers exist;
update baseSuggestedCount to count all occurrences of the fallback signals
(e.g., run a global regex match against body for /Committable
suggestion|Potential issue/gi and use the match length or 0) and keep openCount
logic the same (openCount = actionableCount != null ? Math.max(0,
actionableCount - addressedCount) : Math.max(0, baseSuggestedCount -
addressedCount)), referencing baseSuggestedCount, actionableCount,
addressedCount and body to locate and replace the 1/0 fallback with the match
count.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 78faba5d-fc22-40c4-a73f-14cd6ff7d941
📒 Files selected for processing (4)
src/components/git/DiffFileTree.tsxsrc/components/git/TaskPullRequestReviewFeed.tsxsrc/lib/git/bot-review-comment-summary.tssrc/lib/git/preprocess-github-markdown.ts
Task
PY-46: GitHub Integration Nacharbeiten
Summary
Summary by CodeRabbit
New Features
Style
Refactor
Bug Fixes