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
refactor(renderer): remove the web-terminal-surface-id re-export - #27981
src/renderer/src/runtime/web-terminal-surface-id.ts was a 7-line alias that re-exported src/shared/terminal-surface-id.ts. This PR imports the shared module directly and deletes the alias.
What Changed
Users see no difference.
28 renderer files import isWebTerminalSurfaceTabId, toHostSessionTabId, toWebTerminalSurfaceTabId and related names from shared/terminal-surface-id.
Test mocks of the alias now mock the shared module with the same values. Nothing outside the renderer imports these names, so the mocks cover the same code they did before.
web-runtime-session-legacy-relay-bridged-activation.test.ts, added by fix(ssh): never start a hidden orcad shell for a tab the legacy relay bridge serves #27939 while the barrel PRs were in flight, imports the shared module. Its mock of the deleted web-session-tabs-sync barrel now targets web-session-tabs-sync/tracking-mappings, the module the activation code imports. Before this, the mock was inert.
Net: production −1, tests 0. This PR is about one import path per symbol, not line count.
Why
Phase 3.99 / AGENTS.md rule: no barrels and no re-export shims. With direct imports, each import line names the module a file really depends on, and each test mocks the module the code under test actually calls. One barrel per PR keeps every review mechanical.
Linked Issue
N/A, internal Phase 3.99 cleanup (PR 3.5e).
Visual Proof
N/A, no UI or behaviour change.
Testing
No reference to runtime/web-terminal-surface-id remains.
All 15 changed test files pass (158 tests).
pnpm tc, pnpm lint and pnpm run check:code-quality:changed (0 findings) pass on the whole barrel stack.
I manually tested these changes locally
Automated tests added/updated, or explained why not below
Review
P0/P1 review: my own review plus an independent reviewer.
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
Renderer-only import changes. SSH, wire, mobile and platforms are not affected.
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)
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)
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
📝 Walkthrough
Walkthrough
Renderer production code and tests now import terminal surface ID helpers from the shared module instead of the renderer-local module. The renderer-local re-export module is deleted. Import behavior and test mock behavior remain unchanged. One test also targets the tracking-mappings submodule in its mock.
Priority: ⬇️ Low
Merge Risk:⚪ Minimal · up to 7cf73
This removes a renderer-only import alias without changing the shared helpers or user-visible behavior. The imports and updated test mock resolve correctly, so no material merge risk is indicated.
Pre-merge checks | 5
✅ Passed checks (5 passed)
Check name
Status
Explanation
Docstring Coverage
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 41 files.
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.
Title check
The title clearly and concisely describes the primary change: removing the renderer re-export module.
Description check
The description is complete and focused. It explains the change, rationale, testing, lack of user-facing impact, platform scope, and checklist status. The N/A linked issue is consistent with the state…
✨ 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.
ELI5
src/renderer/src/runtime/web-terminal-surface-id.tswas a 7-line alias that re-exportedsrc/shared/terminal-surface-id.ts. This PR imports the shared module directly and deletes the alias.What Changed
Users see no difference.
28 renderer files import
isWebTerminalSurfaceTabId,toHostSessionTabId,toWebTerminalSurfaceTabIdand related names fromshared/terminal-surface-id.Test mocks of the alias now mock the shared module with the same values. Nothing outside the renderer imports these names, so the mocks cover the same code they did before.
web-runtime-session-legacy-relay-bridged-activation.test.ts, added by fix(ssh): never start a hidden orcad shell for a tab the legacy relay bridge serves #27939 while the barrel PRs were in flight, imports the shared module. Its mock of the deletedweb-session-tabs-syncbarrel now targetsweb-session-tabs-sync/tracking-mappings, the module the activation code imports. Before this, the mock was inert.Net: production −1, tests 0. This PR is about one import path per symbol, not line count.
Why
Phase 3.99 / AGENTS.md rule: no barrels and no re-export shims. With direct imports, each import line names the module a file really depends on, and each test mocks the module the code under test actually calls. One barrel per PR keeps every review mechanical.
Linked Issue
N/A, internal Phase 3.99 cleanup (PR 3.5e).
Visual Proof
N/A, no UI or behaviour change.
Testing
No reference to
runtime/web-terminal-surface-idremains.All 15 changed test files pass (158 tests).
pnpm tc,pnpm lintandpnpm run check:code-quality:changed(0 findings) pass on the whole barrel stack.I manually tested these changes locally
Automated tests added/updated, or explained why not below
Review
P0/P1 review: my own review plus an independent reviewer.
Agent skill upstream boundary
Notes
Renderer-only import changes. SSH, wire, mobile and platforms are not affected.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)