Repository navigation
fix(macos): #1550 缓存 LSP 设置页语言摘要并减少主线程布局 - #1551
Conversation
Lithe Review结论: ⛔ 存在阻塞问题 Findings
Scope Check
Suggestions
Summary摘要扫描把昂贵的文件匹配移出 SwiftUI 渲染路径,并保留 workspace/snapshot/rule 身份和陈旧结果保护,方向与问题目标一致。当前缓存生命周期与请求替换的任务编排仍有可复现的状态一致性和响应性缺口;新增 accessibility 文案也没有走共享 i18n。修复后应重新核对快照更新、取消清理和固定工具链测试证据。 Verification
|
新请求直接启动,消费方离页、替换和重置及时解除等待;模型持有退出中的 已取消扫描,使用唯一工作 ID 拒绝陈旧结果,并正确处理共享消费方和释放。 从同一已应用快照捕获 request 和文件清单,保留现有 LSP 叶子订阅与热缓存。 加载无障碍名称复用 native.loading,原生测试注入真实语言资源并验证中英文 AX。 补齐并发、生命周期、持续快照刷新和原生布局测试,更新所有权笔记及功能矩阵。 同时整合已验证的 preview@0627017d,保留 PR 1lck#1551 原提交 59ea635 的历史。 验证:51 项 Swift 测试、35 项 i18n 测试、5 项补充原生测试和相关静态门禁通过。 本机 Swift 6.4/Xcode 27.1;固定工具链 CI、100ms 目标和 macOS13 验收仍待完成。
1lck
left a comment
There was a problem hiding this comment.
复核当前 head f9d28d9:未发现需要阻塞合并的问题。
旧评审针对 59ea635:最新实现已移除新扫描等待旧任务结束的依赖,使用工作 ID、消费者取消标记和缓存身份拒绝过期结果;补充保持同一 SettingsView 挂载时 README→Go→Java→README 的快照回归;加载提示复用 native.loading,并覆盖应用语言与父 locale 相反的场景。当前 Swift CI 已通过。
本次为静态代码与已有 CI 结果复核,未独立重跑测试或 GUI。100ms 性能目标、macOS 13 运行兼容性和固定工具链下 GUI 性能重测仍是已披露的验证边界。建议同步最新 preview 后由必需检查完成合并门禁;旧提交的阻塞评论不应直接作为当前 head 的结论。
There was a problem hiding this comment.
复核功能修订 f9d28d9,并检查同步 preview 后的 a5c4567:未发现新的阻塞性代码问题。
取消与过期结果隔离、保持 SettingsView 挂载的快照变化回归、native.loading 本地化已覆盖原评审问题。本次还修正两处因基线脚本迁移失效的 Agent Note 命令路径;本地 167 篇笔记检查及最新 Verify Agent Notes CI 通过。
功能判断依据静态审查及此前已有 CI;未独立重跑此 PR 的 GUI/性能测试。100ms 性能目标、macOS 13 实机兼容性仍待验证。当前仍应遵守仓库所需的独立审批和最新 CI 门禁,本次批准不代表可以绕过这些要求。
* fix(ci): align AutoBuild macOS release timeout budgets (#1572) * fix(macos): 修复硬链接文件打开并提供三种保存选择 (#1419) (#1575) * fix(macos): support explicit hard-link save choices Allow regular hard-linked documents to open and require a fresh per-save choice to detach the current path, update shared contents, or cancel. Pause autosave, retain conflict and object-identity guards, and reconcile open aliases after shared writes. Classify document access failures with actionable localized messages, preserve drafts on cancellation and write failures, and add native/workflow/router regressions with updated decision notes and platform evidence. Fixes #1419 * fix(macos): continue explicit hard-link saves after autosave checks * fix(ci): decouple AutoBuild publication from plugin mirrors (#1576) * Merge pull request #1497 from frankxii/windows-optimise-1025 fix(windows): 对齐 Commit 面板与 macOS,并支持隐藏变更列表和父仓库引用选项 * fix(macos): 工作树状态刷新、历史撑满与独立提交面板 (#1579) * fix(macos): 改进工作树历史与状态刷新并复用独立提交面板 * fix(macos): preserve worktree status exclusions and diff commit locking * fix(macos): #1550 缓存 LSP 设置页语言摘要并减少主线程布局 (#1551) * fix(macos): #1550 缓存 LSP 设置页语言摘要并减少主线程布局 * docs: update LSP cancellation validation script paths --------- Co-authored-by: Lichenkang <2188718831@qq.com> * fix(git-host): launch Git through forward-slash paths and report empt… (#1574) * fix(git-host): launch Git through forward-slash paths and report empty version probes On some Windows hosts (disk-encryption or endpoint-security filters), a Git started through a backslash path prints nothing to a captured pipe, while the same executable started through a forward-slash path behaves normally. The version probe therefore returned an empty string, which validate_version reported as "Git 2.31 or newer is required" even for Git 2.48.1, leaving every repository unreadable regardless of the selected executable. - Normalize the resolved executable path to forward slashes on Windows, keeping UNC and verbatim paths untouched. - Treat a successful but empty version probe as a probe failure with its own message instead of a too-old Git, and do not cache it. - Cover the path normalization with a unit test. Refs #1566 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> * test(git-host): cover Windows executable resolution with forward slashes Add a Windows-only test that executable() returns the selected path with forward slashes, so the launch-path normalization cannot be dropped silently. The test fails when the normalization is removed. Refs #1566 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> * perf(windows): 消除 Windows 端 UI 卡顿与补全卡死的根因 (#1577) * perf(windows): deliver LSP diagnostics as one batch per Core drain Each publishDiagnostics event used its own frontend `emit` (a full IPC round trip broadcast to every window) and its own diagnostics store update, which copied both maps per file. Importing a large Java project published hundreds of files at once and the editor stalled behind them. The adapter now keeps the newest set per URI within one `lsp.waitEvents` drain and emits a single `lsp://diagnostics` batch, flushing before a lifecycle change so ordering is kept. The LSP client resolves workspace state once per batch and applies every file with one store update. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * perf(windows): render large Markdown previews without repeated work Code-block highlighting replaced each block with `String.replace` over the whole document, rescanning and copying it once per block: a document with a thousand fences took about 1.9 s, and code containing `$&` or `$1` was corrupted by replacement-pattern expansion. The blocks are now substituted in one pass with a replacer function (about 7 ms). The preview also swapped in the unhighlighted HTML on every edit and then the highlighted HTML, rebuilding and laying out the whole preview twice. It now keeps the current preview until the edited document is highlighted; only an empty preview shows plain HTML first. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * perf(windows): run blocking host commands off the WebView2 UI thread Tauri runs a synchronous command inline on the thread that dispatches IPC, which on Windows is the WebView2 UI thread. Commands that read or write files, walk or delete directories, start processes or register native watches froze painting and input and queued every other invoke while they ran: Java language-server launch resolution (fingerprint, JDT LS and java probes, cache cleanup), toolchain discovery, run configuration resolution and writes, file reads and writes, clipboard paste, terminal and Agent creation, plugin rescans and launches, and document watch registration. These commands are now async and run their body through a shared `run_blocking` helper on Tauri's blocking pool. The develop-lithe skill records the rule together with the batching rule for frequent events. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * perf(windows): move PATH searches and plugin settings I/O off the UI thread Profiling the Windows build showed `get_tool_path` called thirty times while a project opens, each searching every PATH directory on the WebView2 UI thread, and cheap commands such as `plugin:event|listen` waiting up to 1.4 s behind such work. `get_tool_path`, the declarative plugin settings, run/test plan and web file commands, disk-install cancellation and the Agent panel settings commit now run through `run_blocking` as well. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * Merge pull request #1497 from frankxii/windows-optimise-1025 fix(windows): 对齐 Commit 面板与 macOS,并支持隐藏变更列表和父仓库引用选项 * perf(mybatis): index only mapper-named Java files and rebuild on mapper edits The MyBatis index tree-sitter-parsed every Java file in the workspace, and both hosts rebuilt it on every Java edit. On ruoyi-vue-pro this ran 11 times (108 s total, 22 s max) while typing, starving completion requests. - Core reads mapper XML first and parses only Java files whose stem matches a namespace segment (a.b.Outer.Inner names Outer.java). - Windows and macOS rebuild only when an XML mapper or a Java file already paired with a statement changes; newly opened buffers still reload. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * perf(markdown): skip layout for off-screen preview blocks Opening an 86k-line preview spent 26 s in native layout. Top-level text and code blocks now use content-visibility: auto with an intrinsic size hint; tables are excluded because paint containment would clip their overflow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(markdown): drive preview highlighting with a controlled highlighter The preview test waited on a real setTimeout, which the test-stability gate rejects. useHighlightedMarkdown now takes the highlighter as an optional argument (defaulting to highlightMarkdownCodeBlocks), and the test completes each highlight itself. It also asserts that the previous highlighted preview stays visible while an edit is being highlighted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(macos): 工作树状态刷新、历史撑满与独立提交面板 (#1579) * fix(macos): 改进工作树历史与状态刷新并复用独立提交面板 * fix(macos): preserve worktree status exclusions and diff commit locking * fix: preserve settings transactions and queued agent lifecycle * fix(windows): guard background saves, clipboard and terminal ownership --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: 若水 <frankw.wang@qq.com> Co-authored-by: Xiaoyumuxi <23722032@bjtu.edu.cn> * docs: 添加 APINEBULA、TIMI CC 和 Zeus 赞助商 (#1583) * docs: add APINEBULA as the third sponsor banner * docs: add TIMI CC and Zeus to sponsor tables * docs: move Zeus below CCSub and shorten sponsor copy * test(macos): expect the typed symlink error in agent edit rollback (#1582) #1575 made document reads open with O_NOFOLLOW and report a symlink as DocumentFileAccessError.symbolicLink instead of a CocoaError. The rollback test that swaps the created file for a symlink during the trash operation still expected CocoaError, so Swift tests failed on preview. The test now expects the typed error; its checks that the link and its target are left untouched and the recovered copy is removed are unchanged. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> * docs: refresh README product screenshots (#1585) * docs: lead README gallery with IDE workflows (#1587) * docs: remove IDEA comparison annotations from README screenshots (#1588) * docs: 调整 README 徽章并修正发行版链接 (#1589) * docs: center trending badge in README * docs: point release links to current repository --------- Co-authored-by: Xiaoyumuxi <23722032@bjtu.edu.cn> Co-authored-by: 若水 <frankw.wang@qq.com> Co-authored-by: lincoco <77844710+lin-coco@users.noreply.github.com> Co-authored-by: AACS111 <103710223+AACS111@users.noreply.github.com> Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
大型工作区反复进入“设置 › LSP”时,页面会在主线程为语言列表和插件提示重复遍历文件清单,导致高 CPU 和暂时无响应。本 PR 将识别移到工作区持有的后台摘要缓存,并减少设置页渲染中的重复插件发现和分栏尺寸测量;保留语言开关、状态与插件提示行为。
Closes #1550
改动
LanguageToolingFeatureModel持有项目语言使用摘要,以工作区身份、文件快照 UUID 和规范化匹配规则作为键;不遍历或哈希整个文件数组生成键,也不长期缓存文件名。native.loading;热缓存命中不重复发布相同的.ready。sizeThatFits(.unspecified);其他宿主保留原路径,实际窗口边界仍决定面板尺寸。LITHE_SETTINGS_LATENCY_TRACE=1诊断,按同一个真实鼠标输入 ID 关联接收、选择、就绪内容挂载、窗口更新和主队列可运行阶段;避免复用键盘/旧输入,离开时清理窗口观察者。该诊断不关闭正常 FPS 监视器。lsp-control-center-performance功能矩阵记录,保持pending。没有修改公开插件契约、Rust C ABI、设置存储格式或语言服务器启动协议。关闭设置时偶发约 168% CPU 峰值不在本次范围。
Lithe Review 修复与本轮验证(2026-10-28)
AppModel.objectWillChange已能刷新 LSP 叶子。补充保持同一完整 SettingsView 挂载、连续应用 README→Go→Java→README 四份快照的测试,settingsChanges保持 0。native.loading中英文词条;原生 AX 测试使用真实翻译资源,在相反父 locale 下直接断言 “Loading…” / “正在加载…”。preview@0627017d,保留原 PR 提交历史。51 项定向 Swift 测试、7 个 suite 通过;最慢改动测试为原生挂载用例,两种语言合计 1.332 秒,未超过 15 秒预算。35 项 i18n 测试通过。.artifacts/,未上传含本机路径的原始诊断。本轮定向测试命令:
./.agents/skills/write-stable-tests/scripts/test-stability-macos.sh \ --report .artifacts/test-stability/lsp-review.json --suite-timeout-seconds 1800 -- \ --build-system native --jobs 3 \ --filter 'LSPProjectUsageTests|LSPControlCenterPresentationTests|WorkspaceLanguageServerPreferencesTests|AppModelSettingsChangesTests|SettingsPageLatencyTraceTests|LitheSplitPaneCollapseTests|SettingsAppearanceContainerTests'原始版本已有验证与结果
0beb43c936f6上本 PR 的实现;随后已无冲突同步到preview@9a78c66790f2,不把早先的运行结果冒充最新基线或固定工具链 CI 结果。windowUpdated/mainQueueAvailable也不等于显示器物理呈现。preview@9a78c667上通过测试稳定性静态检查、服务边界、运行时包只读、应用构建安全、共享 i18n 检查、212 项功能矩阵、实际 base/head 矩阵变更门禁及 diff 检查。定向测试命令:
./.agents/skills/write-stable-tests/scripts/test-stability-macos.sh \ --report .artifacts/test-stability/lsp-layout-latency.json -- \ --build-system native --jobs 2 \ --filter 'LSPProjectUsageTests|LSPControlCenterPresentationTests|WorkspaceLanguageServerPreferencesTests|SettingsPageLatencyTraceTests|LitheSplitPaneCollapseTests|SettingsAppearanceContainerTests'CI 与待验证项
59ea6353已通过 Swift 6.3.3 / Xcode 26.6 的 Swift 测试和 ARM64 打包 CI;本次修复f9d28d91的固定工具链结果仍待新一轮 CI。PR 保持 Ready;本机使用 Swift 6.4 / Xcode 27.1。