Repository navigation
feat(desktop): Core 固定到 6a14126,带上 Git 忽略批量询问和悬浮缓存 - #2006
Merged
Merged
Conversation
两端都通过 Core 6a14126 获得:同一文档版本的同一位置或同一行 range 内 再次悬浮直接返回保留的答案。写明上限、不保留的答案和清空条件;两端 仍为 partial / pending,原生窗口验收待做。
xiaoyumuxi
marked this pull request as ready for review
November 16, 2026 03:10
18 of 24 tasks
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.
关联 Issue / Linked issue
PR 类型 / Type
改动说明 / What changes
背景 / Why
#1994 和 #1995 的 Core 部分已经合入 Core main,但桌面端还固定在 Core 5802c42(#59),用户拿不到:
directoryFilters),旧实现每个父目录串行起一次git check-ignore。Core Fix WinUI workspace and editor interactions #60 改成按目录层批量询问,算出的排除结果不变。改动 / Changes
scripts/desktop/build-desktop-core.shPINNED_CORE_REVISION从5802c42(Core feat(runtime): expose managed process memory usage #59)升到6a14126(Core fix(settings): refresh locale when language changes #61)。lithe-project的索引排除按目录层、按仓库批量运行git check-ignore,被忽略的目录用一次批量git ls-files判断是否含已跟踪内容。Kubernetes 上,Core 测得prepare_provider_exclusions从 29.2 s 降到 3.1 s,check-ignore进程从 2,179 个降到 14 个,排除结果相同(31,211 个文件)。lsp-engine/src/hover_cache.rs。同一文档版本的同一位置,或答案range在同一行内覆盖的位置,直接用保留的答案完成悬浮请求,结果和服务器答案逐字节相同。executeCommand,插件后端的languageServer/request、languageServer/notify,宿主通知写给插件后端,服务器发来的任何请求或$/progressend,以及会话停止、崩溃、重启时清空。languageServers0 内的补充,没有新增方法、字段或能力版本)。shared/platform-feature-matrix/features/lsp-completion-hover.json:verification增加 Core 6a14126 的悬浮答案保留;两端仍为partial/pending。不在本 PR 范围内 / Out of scope
pending。类型专属:feat
多平台对齐
范围检查 / Scope checks
功能矩阵 / Feature matrix
shared/platform-feature-matrix/features/lsp-completion-hover.json:verification增加 Core fix(settings): refresh locale when language changes #61 的行为、上限和清空条件;两端仍为partial/pending(没有做原生窗口验收)。Fix WinUI workspace and editor interactions #60 不改变能力,只缩短 gopls 开始工作前的等待,没有单独的矩阵条目。./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh(193 个能力通过)和./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/main HEAD(没有平台实现路径变化).artifacts/下生成的矩阵视图插件归属 / Plugin ownership
develop-lithe第三节的自查命令,结果为空lsp-completion-hover是宿主的通用悬浮能力,证据仍是宿主文件UI 验证 / UI evidence
N/A:没有界面变化;悬浮弹窗的布局和交互不变,只是再次悬浮时不再问语言服务器。
统一日志系统 / Structured logging
N/A:没有新的里程碑、终态或失败路径。
界面文案 / i18n
N/A:没有新增或修改文案。
逻辑归属 / Logic placement
lithe-project/lithe-git,fix(settings): refresh locale when language changes #61 在lsp-engine),平台层没有改动gopls性能与内存 / Performance and memory
没有新增常驻进程、轮询或线程;Fix WinUI workspace and editor interactions #60 让 Git 进程数从“与目录数成正比”降到“目录层数 × 仓库数”;fix(settings): refresh locale when language changes #61 的缓存有上限(每个会话 32 个答案、单个 64 KiB,即每个会话最多 2 MiB),属于会话状态,会话结束时随状态释放
主线程上没有新增文件读写、目录遍历或进程启动(宿主代码没有改动)
改动前后的数据:Core Fix WinUI workspace and editor interactions #60 在 Kubernetes c50e5395 上测得
prepare_provider_exclusions29.2 s → 3.1 s(三次分别为 29,203 / 29,212 / 29,281 ms 与 3,651 / 3,095 / 3,105 ms)。桌面端复测:同一棵树打两个包,只差 Core 固定版本(5802c42 和 6a14126),用 Go 插件io.github.lithe-idea.go-support在同一台 Apple M4 上测:Kubernetes c50e5395,打开
pkg/kubelet/kubelet.go(ide-compare.mjs,全新配置首次打开 150 s + 重开 120 s):Lithe-IDEA adf46f5,
desktop/internal/workbench/app.go,每项 5 次(ide-compare-latency.mjs,指针停在Emit上触发悬浮,时间含桌面端固定的 500 ms 悬浮等待):textDocument/hover这个仓库里 gopls 回答一次悬浮只要约 1 ms,所以屏幕上的悬浮时间几乎全是 500 ms 等待,缓存在这里只减少发给服务器的请求,看不出时间差;服务器回答慢时才会缩短再次悬浮的等待。
设置 / Settings
N/A:没有改设置项。
插件契约 / Plugin contract
languageServers0 内的补充)PINNED_CORE_REVISION已升到 6a14126;构建戳.artifacts/desktop/lithe-core/aarch64-apple-darwin/debug/identity.txt显示core-revision=6a1412635557fcd37766faafbf2fccd4a68dc7db、core-source=pinned、core-worktree=clean,桌面端测试经scripts/desktop/desktop-go.sh读到的就是这份契约plugin-rpc没有改动)发行包与资源 / Bundle and resources
N/A:没有新增运行时资源、下载物或缓存目录;悬浮缓存只在内存里。
无用代码与重构 / Dead code and refactoring
验证 / Verification
node scripts/desktop/validate-pins.mjsscripts/desktop/check.sh(gofmt、go vet ./...、go vet -tags dev ./...、go test ./...、go test -tags dev ./internal/buildinfo),从零构建 Core 6a14126 的 debug 库.artifacts/desktop/lithe-core/aarch64-apple-darwin/debug/identity.txtcore-revision=6a14126…、core-source=pinned、core-worktree=clean./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh;./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/main HEADdevelop-lithe第三节的插件归属自查rgscripts/desktop/package-desktop.sh --format app --ad-hoc-sign分别用 Core 5802c42 和 6a14126 打包,ide-compare.mjs在 Kubernetes c50e5395 上测 gopls 启动ide-compare-latency.mjs在 Lithe-IDEA adf46f5 上测悬浮、跳到定义、查找引用各 5 次未能执行的检查和原因:
pending。提交前确认 / Final checks
main(9fb896283)创建,目标main