Skip to content

refactor(orcad): move the Node host adapters out of orcad-entry.ts (fix main lint) - #28530

Merged
Jinwoo-H merged 1 commit into
mainfrom
fix/orcad-entry-max-lines
Oct 14, 2026
Merged

Jinwoo-H merged 1 commit into
mainfrom
fix/orcad-entry-max-lines

Conversation

@Jinwoo-H

@Jinwoo-H Jinwoo-H commented Oct 14, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 3 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​3 $\color{#cf222e}{\Huge{\mathbf{−}}}$​3 0
Prod 2 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​76 $\color{#cf222e}{\Huge{\mathbf{−}}}$​69 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​7

ELI5

Main's lint check fails because one file grew one line past the size limit. This moves a self-contained piece of that file into its own file. Nothing behaves differently.

What Changed

  • New src/main/orcad/orcad-host-adapters.ts holds the Node server's stand-ins for Electron's app environment and secret store (installOrcadHostAdapters, the quit-handler runner), moved verbatim from orcad-entry.ts.
  • orcad-entry.ts imports them; it drops from 420 to ~350 physical lines and back under the 300-line lint limit.
  • Two tests and one e2e fixture that imported installOrcadHostAdapters from orcad-entry now import it from the new module.

Why

#28464 pushed orcad-entry.ts to 301 counted lines, so the Lint step on main (and every PR) fails. The host adapters are a cohesive unit with no dependency on the startup sequence, so they split out cleanly; disabling max-lines is not allowed.

Linked Issue

N/A (main lint fix)

Visual Proof

N/A: refactor with no behaviour change.

Testing

  • pnpm tc:node, oxlint on changed files, pnpm run check:code-quality:changed, check:max-lines-ratchet all pass.

  • orcad-entry, orcad-forked-child-paths, orcad-wsl-guest-shell-path, orcad-launch-contract, orcad-push-startup tests pass (34).

  • Automated tests added/updated, or explained why not below (existing tests cover the moved code)

Fixes main's lint: #28464 left orcad-entry.ts at 301 lines (max 300). No behaviour change.
@coderabbitai

coderabbitai Bot commented Oct 14, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 2ebd0982-6b88-4be7-ac7e-3eb27f6600bd
📥 Commits

Reviewing files that changed from the base of the PR and between 5f134d8 and 5d99ce8.

📒 Files selected for processing: 5
  • src/main/orcad/orcad-entry.ts
  • src/main/orcad/orcad-forked-child-paths.test.ts
  • src/main/orcad/orcad-host-adapters.ts
  • src/main/orcad/orcad-wsl-guest-shell-path.test.ts
  • tests/e2e/fixtures/daemon-generation-profile-store.ts

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

📝 Walkthrough

The PR moves the Orcad app-environment and secret-store adapters, quit-handler execution, and adapter installation into a shared module. The entry point removes its local implementations and imports the shared functions. Two tests and an end-to-end fixture update their installer imports.

Estimated code review effort

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to 5d99c

The extraction preserves the inspected startup behavior, with no identified issue blocking merge after normal checks.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 25.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 5 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main change: moving the Node host adapters out of orcad-entry.ts to resolve the lint issue.
Description check Passed The description includes the main required sections, explains the change and motivation, records the no-behavior-change intent, provides visual-proof justification, and documents testing. Some optiona…
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.
  • Fix all pre-merge checks with AI
✨ Finishing Touches: 💡 2
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
🛠️ Fix failing CI checks: 💡
  • 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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Jinwoo-H
Jinwoo-H merged commit 6741f4f into main Oct 14, 2026
73 of 75 checks passed
star-nebula added a commit to star-nebula/orca that referenced this pull request Oct 14, 2026
…code adoption

Adopt upstream's orcad-host-adapters extraction (drop our duplicate). Keep ZCode
in the CLI-conversation adoption map under upstream's new row-agent shape. Port
upstream's agent-aware preparation-failure notification into the extracted
ai-vault-session-launch-target-notify module the merged call sites use.
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