Skip to content

fix(lint): bring browser-session-registry.ts back under the 300-line limit - #48120

Merged
brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-browser-session-registry-max-lines
Nov 24, 2026
Merged

brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-browser-session-registry-max-lines

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

The code checker allows at most 300 lines in a file. One file ended up one line over, so the check fails on every pull request. This joins two lines into one.

Files Added Deleted Net
Test 0 0 0 0
Prod 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1 $\color{#cf222e}{\Huge{\mathbf{−}}}$​2 $\color{#cf222e}{\Huge{\mathbf{−}}}$​1

What Changed

browser-session-registry.ts was 301 counted lines against the 300-line max-lines lint limit. persistProfiles now passes its filtered list straight to persistMeta instead of through a local variable. It does exactly the same thing.

Why

The lint error fails static analysis for every open PR.

Linked Issue

None; CI fix.

Visual Proof

N/A: no UI or behavior change.

Testing

  • pnpm exec oxlint on the file: no errors.

  • pnpm check:changed: all 53 checks pass.

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below (no behavior change)

  • Every added test fails without this change and avoids the test anti-patterns

Performance

None, because the change only inlines a local variable.

Risk

Level: Low. Same expression, same call. A plain revert backs it out.

Review

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • I stated the risk: what could break, for whom, and how to back it out
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

…limit

Inline one local so the file passes max-lines again; no behavior change.
@coderabbitai

coderabbitai Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

persistProfiles now passes the filtered non-default profile list directly to persistMeta. The persisted profile selection is unchanged.

Merge Risk: Minimal · up to a140f

This is a behavior-neutral refactor that brings the file under the 300-line lint limit. No user-facing or production impact is expected, and it is safe to merge.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the fix and the file: it brings browser-session-registry.ts back under the 300-line lint limit. The raw summary and objectives confirm the change inlines a local variable in persistPro…
Description check Passed The description follows the repository template and covers the required sections. It explains the change in plain language (ELI5), the before and after, and the reason for the change. It states the pe…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the fix and the file: it brings browser-session-registry.ts back under the 300-line lint limit. The raw summary and objectives confirm the change inlines a local variable in persistProfiles to remove one counted line. The title is specific and matches the changeset. It is slightly long at 74 characters, but it is clear.

Full details: Description check

Explanation

The description follows the repository template and covers the required sections. It explains the change in plain language (ELI5), the before and after, and the reason for the change. It states the performance impact, the risk level with a revert path, and a visual proof N/A with a reason. Testing lists the lint and check commands the author ran. The Linked Issue section says 'None; CI fix' and has no issue reference. The template says contributors must link an actual issue, so that section is incomplete. The template also asks for a short explanation of the mechanism, which the description gives briefly. The Review and AI Disclosure sections are empty or absent, and the testing checklist marks manual testing as done while the Testing section lists only commands. These gaps are minor for a one-line lint fix, so the description is mostly complete.

  • 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.

Share

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: 74ebec24-21f1-4e45-b7f7-cc3381f2de7e
Commits

Reviewing files that changed from the base of the PR and between 987c5e5 and a140fc9.

Files selected for processing: 1

  • src/main/browser/sessions/profiles/browser-session-registry.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 6 remain after this review.

@brennanb2025
brennanb2025 merged commit 66d362d into main Nov 24, 2026
54 checks passed
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