Repository navigation
Fix mobile Markdown read and save in inactive desktop splits - #10161
GoodFarming wants to merge 2 commits into
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📥 CommitsReviewing files that changed from the base of the PR and between 68cd8e0e88f9d157b73fb030d627e58eb4fd280c and b1dda18. 📒 Files selected for processing (6)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe mobile Markdown bridge now resolves file identifiers from unified editor tabs. The test harness adds shared fixture IDs, resets worktree-scoped editor state, and optionally creates unified tabs when it opens Markdown files. Tests cover fallback reads, unknown tab IDs, split-group reads and saves, and active group and tab state. An obsolete tab-order mock was removed. Priority: ➖ Normal Merge Risk: ⚪ Minimal · up to The change lets paired mobile clients read and save Markdown in inactive desktop split groups without changing which group is active. Unknown or ineligible tabs still fail with tab_not_found. No actionable merge risk remains. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The change restores access to already-open Markdown files across splits while preserving workspace scoping and existing file permissions. No new access-control weakness was established. Interruption and recovery behavior remains incompletely verified. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 6680e557-01ce-409c-9600-6fb284930b32
📥 Commits
Reviewing files that changed from the base of the PR and between 8a23618 and be72a418f9b88a968acee4b7d8cb03a60501b150.
📒 Files selected for processing (4)
src/renderer/src/runtime/mobile-markdown-bridge-save-guards.test.tssrc/renderer/src/runtime/mobile-markdown-bridge-test-harness.tssrc/renderer/src/runtime/mobile-markdown-bridge.test.tssrc/renderer/src/runtime/mobile-markdown-bridge.ts
💤 Files with no reviewable changes (1)
- src/renderer/src/runtime/mobile-markdown-bridge-save-guards.test.ts
be72a41 to
850f1f0
Compare
850f1f0 to
68cd8e0
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 12dfe5ab-e7ce-4423-8ca3-e9edbf840814
📥 Commits
Reviewing files that changed from the base of the PR and between f713739 and 68cd8e0e88f9d157b73fb030d627e58eb4fd280c.
📒 Files selected for processing (4)
src/renderer/src/runtime/mobile-markdown-bridge-save-guards.test.tssrc/renderer/src/runtime/mobile-markdown-bridge-test-harness.tssrc/renderer/src/runtime/mobile-markdown-bridge.test.tssrc/renderer/src/runtime/mobile-markdown-bridge.ts
💤 Files with no reviewable changes (1)
- src/renderer/src/runtime/mobile-markdown-bridge-save-guards.test.ts
🚧 Files skipped from review as they are similar to previous changes (1)
- src/renderer/src/runtime/mobile-markdown-bridge.ts
Preserve the contributor lookup fix from stablyai#10161 and add real paired save proof plus workspace and content-type boundaries.
3666860 to
b1dda18
Compare
ELI5
A phone or paired client can read and save an open Markdown file in another desktop split without moving the desktop selection.
What Changed
Markdown requests now resolve the requested editor tab across that workspace's existing tab registry, then match its exact backing file. Previously lookup used the desktop-active split's navigation order, so an open file in another split returned
tab_not_found. The existing save controller, content version checks, file-owner guards, and direct file-ID hydration fallback remain in use.Why
The tab registry already identifies every split's editor. Reading it directly fixes lookup without activating a split, adding a cache, or changing editor libraries. This preserves GoodFarming's original #10161 fix and tests, with added workspace/type boundary controls and real paired save coverage. The commit retains GoodFarming as author.
VS Code's EditorService.findEditors likewise searches across groups unless a group is explicitly supplied. The exact Tiptap 3.31.3 and Monaco 0.55.1 sources were inspected; their parsing/model APIs are unchanged.
Linked Issue
Existing contribution #10161; no separate issue or duplicate PR.
Visual Proof
Before: the real paired read returned
tab_not_found; the Markdown pane retained its original text.After: paired Save reaches disk and updates the Markdown pane while the sibling pane stays active.
Testing
Exact head:
b1dda18a2d6d208cd35f9ce61ac2229983554154; base996924081935cc67e94ccf609d9eded3f689b666includes localization fix #25494.tab_not_found.pnpm lintreaches five existing mobile import-cycle warnings inclient-context.tsx,host-client-hooks.ts,fit-scale.ts(two), andmouse-report-cell.ts. These unchanged cycles are being repaired separately; this PR adds none.Review
Independent source review checked worktree and editor-type scoping, exact backing-file matching, hydration compatibility, and preservation of save/owner boundaries. No new dependency, IPC, wire field, shortcut, or global model scan.
Agent skill upstream boundary
Notes
Physical Android, Windows/Linux desktop, and direct SSH were not exercised by this new UI proof. The fix changes host-side tab lookup only; existing remote file ownership and save guards remain authoritative.
Checklist