Repository navigation
Conversation
10 of 11 tasks
Collaborator
Collaborator
|
Closing since this landed in #47136, with you credited as co-author. Thanks for the fix! |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
Browser tabs opened by the headless server can belong to a workspace even though their isolated browser process has no workspace data. The server now reports the workspace it recorded instead of returning
worktreeId: null.What Changed
Project the parent registry's workspace ID when rewriting Electron sidecar tab results. This covers tab listings and nested tab results, including popups that inherit their opener's workspace. Unscoped tabs continue to report
null.Why
The isolated sidecar deliberately has no workspaces. The parent registry already holds the authoritative ownership and uses it to scope operations, so its public metadata should agree with that ownership.
Linked Issue
Partial fix for #42718: correct the null workspace metadata. Keep the issue open pending reproduction of paired-client placement and cookie behavior. This change does not implement client routing or share browser sessions.
Visual Proof
N/A
This changes server-side JSON metadata only; no rendered UI or interaction changes. The owning registry reproduction returned
worktreeId: nullbefore andworktreeId: "workspace-a"after for the same registered tab and its popup.Testing
The real registry regression fails with only the production overlay removed and passes when restored (1 test). It exercises a workspace tab, inherited popup, unscoped tab, and nested tab result with hardcoded expectations.
Normal
pnpm test src/main/orcad/browser-providers/electron/electron-sidecar-tab-registry.test.ts --maxWorkers=1passed (1/1), including workspace package build and the native runtime guard. The actual tracked pre-commit hook passed lint, JS plugins, AST gates, React Doctor, and formatting.Immediately before pushing,
ORCA_CODE_QUALITY_BASE=upstream/main pnpm check:changed --base=upstream/main --maxWorkers=1passed all 25 checks in 179 seconds, including related unit tests, node/web/CLI typechecks, formatting, lint, changed-code quality, import boundaries, localization extraction, test-file runners, and all selected ratchets. Windows validation used the supported private pnpm task-state directory with automatic dependency verification disabled to preserve the shared checkout's dependency links.Full repository lint/typecheck/test/build and paired Windows-desktop/Linux-server cookie placement have not been validated locally.
Risk
Level: Low for the metadata change.
The public workspace field now comes from the server registry. Incorrect registry ownership would surface as incorrect metadata; no ownership, cookie partition, browser placement, saved state, or routing is changed. A plain revert restores the prior projection.
AI Disclosure
Implemented and reviewed with OpenAI Codex assistance. The regression was supplied by another Codex worker and adopted by the primary owner; that handoff is not independent human review.
Review
The change uses existing registry state with one map lookup per rewritten tab. It introduces no platform-specific paths, shortcuts, or process launches and does not assume a Git worktree. Local, remote/SSH, mobile callers, agents, and integrations receive the same JSON shape with corrected ownership metadata. Authentication and browser contexts retain their existing behavior. The broader paired-client report remains unverified, so this PR stays draft.
A second Codex agent reviewed exact commit
35dad151without edits, tests, or app launches and found no blocking defect in this partial metadata fix. It checked the parent registration/sidecar boundary, popup inheritance, unknown nested results, unscoped tabs, and regression quality, and confirmed that top-level create/switch shapes and paired placement/cookies remain unchanged.Agent skill upstream boundary
Notes
Remaining work: reproduce explicit-workspace tab creation on a paired Windows desktop/Linux server and verify client placement, split placement, and authenticated session reuse against current upstream routing.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (broader validation remains for CI)