Repository navigation
Conversation
|
Important Review skippedWe couldn't safely recover the incremental review. No full review was started, and the last reviewed checkpoint was preserved. Retry later, or explicitly request a full review by commenting You can disable this status message by setting the Use the checkbox below for a quick retry:
Walkthrough
Priority: Severity of issue fixed: Medium Merge Risk:
|
| Check name | Status | Explanation |
|---|---|---|
| Title check | ✅ Passed | The title clearly and concisely describes the main change: an explicit Actions choice takes precedence over the legacy flag. |
| Description check | ✅ Passed | The description explains the user impact, changes, rationale, linked issue, testing, and compatibility considerations. It addresses the required visual-proof section and includes the repository checkl… |
| Linked Issues check | ✅ Passed | Issue #25576 requires an explicit 'actions' choice to override terminalLinkActionPopoverEnabled: false, while profiles without the new field retain the legacy fallback. `terminalLinkClickBehaviorF… |
| Out of Scope Changes check | ✅ Passed | The resolver, default-setting change, and tests all support issue #25576. Removing the injected default is needed to distinguish an explicit user choice from a legacy profile with no choice. No unrela… |
| Docstring Coverage | ✅ Passed | 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 2 files. |
- Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
- Resolver now honors every explicit choice —
terminalLinkClickBehaviorForreturns'actions','open', or'none'directly and consults the legacyterminalLinkActionPopoverEnabledflag only when the new field is unset, so an explicit'actions'is no longer clobbered to'none'by a legacyfalse. - Regression test added — pins
{ terminalLinkActionPopoverEnabled: false, terminalLinkClickBehavior: 'actions' } → 'actions'. I confirmed this case is red against the pre-change resolver, so it is real coverage rather than theatre.
I traced the shared resolver's consumers (terminal-pane-mount-preparation.ts, BrowserTerminalLinkActionsSetting.tsx, and use-native-chat-link-actions.ts). The settings control and terminal click handling read the shared function and are fixed; the native-chat path's duplicate branch only handles the undefined legacy case, and its explicit-value path routes through the same resolver, so it is covered too. Legacy-only profiles resolve exactly as before, as the untouched existing cases pin. The unit test file passes locally (3/3).
deepseek-v4.1-flash (free via Pullfrog for OSS) | 𝕏
|
Correction to the review above. I approved before tracing the load path; that was wrong. This change reintroduces the popover for legacy profiles that explicitly turned it off. Why the read-side fix is not sufficient
Before this PR, that injected EvidenceA scratch probe run through the real load path ( Expected Path forwardThe resolution semantics can't be fixed at the read layer alone, because an explicit Manual verification: the settings control's bounce is fixed, but the legacy opt-out regression is the more serious effect.
|
|
The self-correction was right and the follow-up ✅ was not — the defaults-injection path is exactly as described, and it defeated the read-side fix for silent legacy profiles. Confirmed by a red test through the real load shape ( |
There was a problem hiding this comment.
ℹ️ No critical issues — the default removal is correct and necessary; one documentation nit in the new test.
Reviewed changes
- Removed the injected
terminalLinkClickBehaviordefault —buildDefaultSettingsno longer seeds'actions'. This is required for the resolver fix to preserve a legacy opt-out:normalizeLoadedGlobalSettingsspreadsdefaults.settingsbeneath the parsed profile, so a default here would arrive indistinguishable from an explicit choice and the resolver would return'actions'instead of the legacy'none'. - Resolver honors all three explicit values — unchanged from the prior commit; the settings control, terminal click handling, and explicit-value native-chat path all route through it.
- Added a stored-legacy-profile test — spreads
getDefaultSettingsunderterminalLinkActionPopoverEnabled: falseand pins'none'.
I traced the default's source into the real load chain (prepareLoadedTerminalSettings builds defaults.settings from getDefaultSettings) and confirmed terminalLinkClickBehavior is not a retired key, so explicit writes persist. The focused test file plus constants, normalize-loaded-global-settings, and native-chat link-action suites all pass (50 tests).
ℹ️ Nitpicks
- The new test's name and comment describe a state this commit removes: "keeps the legacy opt-out when defaults inject actions" and "arrives here with the default injected". After this commit
getDefaultSettingsno longer injectsterminalLinkClickBehavior, so nothing is injected — and if an'actions'default were injected, the resolver's explicit-value branch returns'actions', so the test's'none'assertion would fail. The test is a good guard against re-adding that default; just reword the name/comment to say so (e.g. "resolves a stored legacy profile to the legacy opt-out").
deepseek-v4.1-flash (free via Pullfrog for OSS) | 𝕏
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/renderer/src/components/terminal-pane/terminal-link-click-behavior.test.ts (1)
31-42: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueFix the stale comment in the new test.
The comment in lines 32-36 says that defaults inject
actionsinto the profile. This PR removes that default, so the comment is now wrong. The test still checks the correct behavior. It guards against a defaults regression that would re-addterminalLinkClickBehavior.Update the comment to say that defaults must not set
terminalLinkClickBehavior. Update the test title in the same way.📝 Proposed fix
- it('keeps the legacy opt-out when defaults inject actions into a stored profile', () => { - // Mirrors the real load chain: normalize-loaded-global-settings spreads - // defaults.settings beneath the parsed profile, so a legacy profile that - // stored only terminalLinkActionPopoverEnabled: false (no - // terminalLinkClickBehavior on disk) arrives here with the default - // injected. The legacy opt-out must still win. + it('keeps the legacy opt-out when a stored profile is merged over defaults', () => { + // Mirrors the real load chain: defaults are spread beneath the parsed + // profile. Defaults must not set terminalLinkClickBehavior, or a legacy + // profile with only terminalLinkActionPopoverEnabled: false would lose + // its opt-out.
ℹ️ Review info
⚙️ Run configuration
- Configuration used: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
ed44d6f0-f63f-4c09-bafd-7738b1050ad6
📥 Commits
Reviewing files that changed from the base of the PR and between 490271fcf6e9ea33a1d53fae566e9770360b09c4 and d0a235133c231947e59125f8e160b6a87a4704e0.
📒 Files selected for processing (2)
src/renderer/src/components/terminal-pane/terminal-link-click-behavior.test.tssrc/shared/default-global-settings.ts
💤 Files with no reviewable changes (1)
- src/shared/default-global-settings.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
d0a2351 to
52653ca
Compare
|
Rebased onto current @nwparker gentle ping whenever you get a chance — happy to adjust anything. |
… legacy flag terminalLinkClickBehaviorFor only treated 'open' and 'none' as explicit, so a profile with the legacy terminalLinkActionPopoverEnabled: false snapped an explicit 'actions' choice back to 'none' — the settings control bounced and plain-clicking links did nothing until the legacy flag was hand-edited. All three values of the enum are explicit user choices now; the legacy flag only answers for profiles that never set the new field, which is what kept older profiles behaviorally identical in the first place. Fixes stablyai#25576 Generated-by: GLM-5.3-Flash (ZCode)
Follow-up to the resolver fix: normalizeLoadedGlobalSettings spreads DEFAULT settings under every loaded profile, and the defaults carried terminalLinkClickBehavior: 'actions' — so a legacy profile that opted out via terminalLinkActionPopoverEnabled: false (and never set the new field) reached the resolver as an explicit 'actions' and the new early-return flipped its opt-out back on. The resolver's own ': actions' fallback already owns the default behavior, so the injected value was redundant; dropping the key restores genuine absence, and the explicit choices from stablyai#25576 still win. Spotted by pullfrog's self-correction on the PR. Generated-by: GLM-5.3-Flash (ZCode)
|
Thanks @ggbdpq for the fix and the clear explanation of both approaches. #25576 is already fixed on main by #26853 (56d25b0). |

ELI5
If an old Orca profile had the link popover turned off, choosing Actions for plain-click in Settings would immediately snap back to Leave to terminal, and plain-clicking links did nothing. The old off-switch was overriding the brand-new choice. Now an explicit choice always wins; the old flag only answers for profiles that never chose.
What Changed
terminalLinkClickBehaviorFortreated only'open'and'none'as explicit values of the newterminalLinkClickBehaviorfield;'actions'fell through to the legacyterminalLinkActionPopoverEnabledcheck and resolved to'none'when that flag wasfalse. All three enum values are explicit user choices now — the legacy flag is consulted only when the new field is unset, which is the exact condition the function's docstring ("keeping older profiles behaviorally identical") was written for. Settings control and click handling read the same shared function, so the control no longer bounces and plain click works.Why
The new field is the user's explicit intent in all three of its values; the legacy flag predates it and was only ever meant to answer for profiles that never set the new field. A read-side fix treats every consumer at once (the settings control, click handling, and the native-chat path all route through this function), rather than compensating at each write site. Older profiles (new field absent) resolve exactly as before, verified by the untouched existing cases.
Linked Issue
Fixes #25576
Transparency note
#25591 addresses the same issue from the write side (writing the legacy flag alongside the explicit choice, plus a loaded-settings migration). Both PRs were opened independently within the same window; this one fixes the resolution semantics at the shared read so every consumer and every write path is covered, and leaves the legacy flag untouched for profiles that never chose. Happy to defer to whichever approach the maintainers prefer.
Visual Proof
N/A for attached media in this environment (headless run). Behavior is pinned by tests: the new case (
terminalLinkClickBehavior: 'actions'+terminalLinkActionPopoverEnabled: false→'actions') was red before the change (expected 'none' to be 'actions'); the pre-existing explicit-openand legacy-only cases are untouched and still pass, pinning both the override and the old-profile behavior.Testing
Commands actually run locally (macOS): target test file red→green (1 failed → 3 passed); adjacent link-click suites 36 passed total;
pnpm tcexit 0;oxlint/oxfmt --checkclean on both touched files. The settings-control bounce itself was not exercised in a running app — the control and the click path share this resolver, which is what the tests pin.AI Disclosure
Investigation scoping and coding by GLM-5.3-Flash (ZCode agent); orchestrated, reviewed and committed by a main agent with the same model, human overseeing.
Agent skill upstream boundary
docs/reference/agent-skill-sharing-upstream-boundary.mdand copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.Notes
Two-line resolution change plus a test; no wire/compat impact (the setting's stored shape is untouched), no platform-specific paths, SSH unaffected.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)