You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(git): preserve commas in legacy history decorations - #35658
On Git older than 2.43, the history panel cannot use %(decorate:...) and falls back to parsing %D. That fallback split the decoration string on every ,. Ref names may legally contain commas (e.g. feat,one), so such branches, remotes, and tags showed truncated badges with the wrong name and id.
Fix
Split the legacy %D output on ", ", the exact separator Git uses between decorations. Ref names cannot contain spaces, so the separator can never occur inside a name. The modern \x1f path is unchanged.
Validation
Added a parser regression test covering a branch, remote, and tag with commas in the legacy format; it fails with the old separator and passes with the fix.
pnpm test src/shared/git-history.test.ts: 13/13 pass.
pnpm check:changed --maxWorkers=2: all 21 checks pass.
No actionable comments were generated in the recent review.
Recent review info
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: 6f1d8910-9b44-486d-9c8a-77e94eb34e5a
Commits
Reviewing files that changed from the base of the PR and between fa2a5d2 and d0ca901.
Files selected for processing: 2
src/shared/git-history-log-parser.ts
src/shared/git-history.test.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.
Walkthrough
The legacy Git decoration separator changes from a comma to a comma followed by a space. A parser test checks that commas within branch, remote-branch, and tag names remain part of each name, and that each reference is categorized correctly.
Priority: Low
Severity of issue fixed: Low
Merge Risk: Minimal · up to d0ca9
The parser change correctly preserves commas in legacy Git decorations without leaving an identified merge-blocking risk.
Pre-merge checks: 4 · 1
Failed checks: 1 warning
Check name
Status
Explanation
Resolution
Description check
The description clearly explains the problem, fix, mechanism, and validation. However, it does not use the required template sections and omits the Linked Issue, Visual Proof or N/A statement, AI Disc…
Update the description to include the required template headings and information. Add the linked issue, state N/A with a reason for Visual Proof, complete Testing and checklist items, and address the remaining required sections.
Passed checks: 4 passed
Check name
Status
Explanation
Title check
The title clearly identifies the main change: preserving commas in legacy Git history decorations.
Docstring Coverage
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage
Explanation
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 2 files.
Full details: Description check
Explanation
The description clearly explains the problem, fix, mechanism, and validation. However, it does not use the required template sections and omits the Linked Issue, Visual Proof or N/A statement, AI Disclosure, Review, Notes, Agent skill upstream boundary, and Checklist sections.
Resolution
Update the description to include the required template headings and information. Add the linked issue, state N/A with a reason for Visual Proof, complete Testing and checklist items, and address the remaining required sections.
Finishing Touches
📝 Generate docstrings
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
On Git older than 2.43, the history panel cannot use
%(decorate:...)and falls back to parsing%D. That fallback split the decoration string on every,. Ref names may legally contain commas (e.g.feat,one), so such branches, remotes, and tags showed truncated badges with the wrong name and id.Fix
Split the legacy
%Doutput on", ", the exact separator Git uses between decorations. Ref names cannot contain spaces, so the separator can never occur inside a name. The modern\x1fpath is unchanged.Validation
pnpm test src/shared/git-history.test.ts: 13/13 pass.pnpm check:changed --maxWorkers=2: all 21 checks pass.