Repository navigation
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. ℹ️ Recent review info
Walkthrough
Priority: Merge Risk:
|
6422289 to
bb1b26c
Compare
The terminal link provider caches filesystem existence per pane, but the
cache had no expiry on negatives. A path printed a moment before its file
exists (e.g. an agent announcing a file it is about to write) got cached
as "missing" and stayed un-clickable forever, even after the file landed —
while a later mention of the same path resolved fine.
Give negative results a short TTL: a cached "missing" older than ~10s is
treated as a cache miss so the next hover re-probes the filesystem.
Positives stay cached (files rarely vanish mid-session, and a stale
positive fails gracefully on open). Cache entries become
{ exists, checkedAt }; both readers (the link provider and the click
fallback) go through the shared read helper so the TTL applies uniformly.
Refs stablyai#5024
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
bb1b26c to
f267903
Compare
|
Rebased onto current Conflict resolution:
|
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: 4bfa2c49-dad9-4751-a833-7013de9ee273
📒 Files selected for processing (10)
src/renderer/src/components/terminal-pane/terminal-file-link-hit-testing.tssrc/renderer/src/components/terminal-pane/terminal-link-click-fallback.test.tssrc/renderer/src/components/terminal-pane/terminal-link-handlers.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-batching.test.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-buffer-fixtures.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-link-detection.test.tssrc/renderer/src/components/terminal-pane/terminal-link-worktree-root-activation.test.tssrc/renderer/src/components/terminal-pane/terminal-pane-mount-preparation.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.test.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.ts
Included review availability: Your plan provides up to 10 included reviews per hour; 6 remain after this review.
Overlapping hover scans can re-probe the same expired missing path. Stamp each probe with its start time and drop a result older than the cached one, so a late "missing" no longer hides a link a newer probe found.
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: f606c454-6c00-44e6-ad71-14f0578af1ae
📒 Files selected for processing (4)
src/renderer/src/components/terminal-pane/terminal-link-handlers.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-link-detection.test.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.test.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.ts
Included review availability: Your plan provides up to 10 included reviews per hour; 3 remain after this review.
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: 2a869f7a-c611-4369-8973-642f5bd08e37
📒 Files selected for processing (7)
src/renderer/src/components/terminal-pane/terminal-link-click-fallback.test.tssrc/renderer/src/components/terminal-pane/terminal-link-handlers.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-buffer-fixtures.tssrc/renderer/src/components/terminal-pane/terminal-link-provider-link-detection.test.tssrc/renderer/src/components/terminal-pane/terminal-link-worktree-root-activation.test.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.test.tssrc/renderer/src/components/terminal-pane/terminal-path-exists-cache.ts
🚧 Files skipped from review as they are similar to previous changes (3)
- src/renderer/src/components/terminal-pane/terminal-link-provider-buffer-fixtures.ts
- src/renderer/src/components/terminal-pane/terminal-link-click-fallback.test.ts
- src/renderer/src/components/terminal-pane/terminal-link-provider-link-detection.test.ts
Included review availability: Your plan provides up to 10 included reviews per hour; 0 remain after this review.
|
| if (existing && existing.sequence > probe.sequence) { | ||
| return |
There was a problem hiding this comment.
Freshly found paths stay missing
When two hovers check the same path at once, the earlier check can find a newly created file after the later check has returned “missing.” This guard discards the result that found the file because that check started first. The negative result then keeps the link unavailable for up to another 10 seconds, despite a check confirming the file exists.
There was a problem hiding this comment.
Keeping the existing start-order policy after explicitly reviewing this trade-off. At 2500c3698f23f7bd8a87e14a1d503f6ccd08ecc8, the later-started probe wins, including when an earlier-started positive completes last. The positive-producing callback still constructs its own link, but subsequent cache consumers can retain the newer negative for the remainder of its existing 10-second TTL. Expired negatives are misses, and repeated hits do not extend that TTL.
That delay is real and accepted, not claimed fixed or disproved. Completion order does not establish filesystem observation order, especially across remote calls; favoring positive results would change the deliberately tested precedence rule. We are retaining the current rule and its regression coverage, without changing expiry or adding probe coordination. Parent reran 52 focused tests and full pnpm tc; all pass.
Preserve the contributor TTL and overlapping-probe ordering through current local and paired-host target resolution. Co-authored-by: mmarabel <[email protected]>
# Conflicts: # src/renderer/src/components/terminal-pane/terminal-file-link-hit-testing.ts
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upstream v1.4.240 (stablyai#6282) expires terminal path-existence misses with its own {exists, checkedAt} cache, so the fork fix 078ffe8 was dropped in the rebase. Its two seam tests asserted the fork's 3s TTL constant and go with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Problem and fix
A path printed before its file exists can stay unclickable for the rest of the terminal session. Orca remembers the first missing result even after the file appears. Missing-path answers now expire after 10 seconds, so the next hover or direct click can find the new file.
The change keeps the existing cache bound and host scoping, preserves positive answers, and prevents older overlapping probes from overwriting newer results. Current main moved probing into shared target resolvers; the fix follows those routes for local, SSH and paired-host paths. The generic cache API used by native chat remains unchanged.
Refs #5024. Preserves @mmarabel's exact original head
2500c3698f23f7bd8a87e14a1d503f6ccd08ecc8, implementation and commit history, refreshed onto main120f01331ca7c5785da2e529ad698ced18bd53f6.Reproduction and validation
On untouched current main, a real Bash terminal printed a missing file path. After hovering it, creating the file through the shell and waiting 11 seconds, the original pane still offered no link, although the production filesystem API reported the file existed. A fresh pane linked the same file immediately.
With this head, the same real flow links the newly created file in the original pane. An actual modifier-click opens its contents in Orca's editor. Both runs used a hidden, unfocused Electron window and a real folder workspace; no mocked filesystem answers, manufactured cache entries or fake clocks were used in this reproduction.
Visual proof
Before: the path remains plain after the real file appears in Explorer.
After: the same flow produces an active underlined path; modifier-click opens the file in Orca.
The clicked file renders the text written by the real shell.
Risk and limits
LOW source risk, pending fresh exact-head CI. Reviewed head
818fb4ffece0acbca389720ac7c27affa8e57460, treec7a1b841674bb0ebd174b365fc8c1a887353b45b. A negative answer can remain cached for up to 10 seconds; positive answers retain their existing lifetime. No wire protocol or stored-data format changes. Native macOS flow verified; Linux, Windows, SSH and mobile hardware were not exercised. Existing remote authority and compatibility paths are covered by focused tests.