Skip to content

fix(desktop): 同步 Viva 上游至 46b10fdf(v0.6.6+)并更新固定版本 - #2220

Merged
1lck merged 1 commit into
mainfrom
chore/sync-viva-46b10fd
Nov 20, 2026
Merged

1lck merged 1 commit into
mainfrom
chore/sync-viva-46b10fd

Conversation

@1lck

@1lck 1lck commented Nov 20, 2026

Copy link
Copy Markdown
Owner

关联 Issue / Linked issue

PR 类型 / Type

  • fix:缺陷修复(同步 Viva 上游并升级固定版本,无用户可观察行为变化)

改动说明 / What changes

背景 / Why

为桌面端 desktop-v0.8.10 发版执行 .agents/skills/release-lithe/SKILL.md 与 .agents/notes/implemented/process/2026-11-11-viva-fork-maintenance-and-commit-pin.md 规定的发版前 Viva 上游同步流程。将 Lithe-IDEA/Lithe-viva 的 main 与 vivaui/viva:main 对齐后,更新 desktop/go.mod 与 desktop/go.sum 固定到最新 fork main。

改动 / Changes

  • desktop/go.mod、desktop/go.sum:
    • require github.com/vivaui/viva 从 v0.6.6-0.20261119025243-bd396bc23c0f 升至 v0.6.7-0.20261120014117-f5b634bbcebf(上游基线 f5b634bb)。
    • replace github.com/vivaui/viva 从 github.com/Lithe-IDEA/viva v0.6.6-0.20261119170518-c7bffddf8794 升至 github.com/Lithe-IDEA/viva v0.6.7-0.20261120025921-46b10fdfd80d(fork PR Lithe-IDEA/Lithe-viva#48 合入后的 main)。

Viva 同步报告(按 2026-11-11 Note 要求)

  1. 基线:
    • 同步前 fork main:c7bffddf(基于上游 bd396bc)。
    • 合入的上游提交范围:bd396bc..f5b634bb(4 个提交:a5b102b0 Page.RouteWheel/Wheel 拆分、e2e6a075 v0.6.6 发布说明、0a00a30e docs、f5b634bb TabIconOnly())。
    • 同步后 fork main:46b10fdfd80d6d656d5a9cf81050333ffd1e07fd;desktop/go.mod 新固定伪版本 v0.6.7-0.20261120025921-46b10fdfd80d;已同步上游 tag v0.6.6 到 fork origin。
  2. 上游变化对 Lithe 的影响:
    • 新增 Page.RouteWheel 与 Tabs.TabIconOnly();Lithe-IDEA 当前未调用这两个新 API,无行为或编译影响。
  3. Fork 补丁状态:
    • 尚未进入上游的活跃补丁保留在 fork(含 fix/popover-wheel-stays-in-panel 即 vivaui/viva#349、fix/tree-disclosure-in-base、fix/tooltip-arrow-border、codex/2199-list-clamp-release、feat/ui-textview、lithe/windows-payload-staging 等),Lithe-viva PR feat(search): share workspace search index #48 已以 --merge 合入上游,未触发任何 patch 被取代或 revert。
  4. 冲突与解决:
    • 唯一冲突在 fork base/page.go 的 RouteWheel 末尾:上游 a5b102b0 将 p.baseScroll(event) 从 RouteWheel 移到 Wheel;保留上游移除 p.baseScroll 的结构,同时保留 fork PR Add Windows CI workflow configuration #40(vivaui/viva#349,上游仍 OPEN)的浮层拦截 if panel >= 0 && !manual { return gfx.EventResult{Handled: true} },确保弹窗/浮层上的滚轮仍不会穿透到底层,且宿主从 OnScroll 转发到 RouteWheel 时不会死循环。Lithe-IDEA 调用点无需修改。
  5. [Feature] 在 Lithe-IDEA/viva 补齐输入框禁用/只读、Tree 横向滚轮与行内 label、Splitter 按键路由,移除 Lithe 的对应绕过代码 #1821 绕过代码核查:
  6. fork 验证:
    • Lithe-viva 本地运行 go vet ./... 通过;go test ./... 除 cmd/viva 在 macOS 27 SDK 下因固件使用 min_system = 12.0 触发的既有部署目标不匹配失败外其余全部包通过;GOOS=windows GOARCH=amd64 go build ./... 与 GOOS=windows GOARCH=arm64 go build ./... 均通过;git merge-base --is-ancestor upstream/main main 返回 0。
  7. Lithe 侧验证:见下方“验证”。

不在本 PR 范围内 / Out of scope


类型专属:fix

复现与根因

  • 复现步骤、实际结果、期望结果:无用户可观察缺陷;按 release-lithe 与 2026-11-11-viva-fork-maintenance-and-commit-pin.md 在发版前同步 Viva 上游并升级固定版本。
  • 根因(引入该行为的提交或 PR,用 git log -S 或 git blame 查):不适用(发版前常规同步)。
  • 影响平台:macOS、Windows、Linux(共用 desktop/go.mod)。

检查项

  • [N/A] 已先写回归测试,确认它在修复前失败、修复后通过:纯依赖基线同步,无行为缺陷修复;已运行桌面全量 Go 单元测试与 fork 测试套件验证兼容性。
  • [N/A] 无法自动化时,已写明手动复现与验证步骤:已自动化运行 Go 测试与交叉编译。
  • 已搜索被修改函数、类型、契约字段的全部调用方(含另一平台、插件、SDK、脚本和按字符串分发的调用):RouteWheel 与 TabIconOnly 在 desktop/ 中当前均无调用方。
  • 已检查另一平台是否有同类缺陷:共用 desktop/go.mod,已在 fork 验证 Windows amd64/arm64 编译。
  • 只改了修复所需的代码,没有夹带重构;修复过程中发现的其他问题已提交 Issue:仓库当前无 refactor 标签(按 develop-lithe 第九节不自行创建标签),已发现的存量项为 desktop/internal/pluginview/render.go:24,140 的 2 条 viva vet kept-context 提示(#2183 引入)及 desktop/internal/fileicons/icons*.go 注释头与 README.md 的 3 行差异(#2141 引入)。
  • [N/A] 修复改变了行为约束或容易复发,已在 .agents/notes/implemented/bug-fix/ 记录:行为约束未变。

范围检查 / Scope checks

功能矩阵 / Feature matrix

  • [N/A] 已更新 shared/platform-feature-matrix/features/<id>.json:本次仅升级 desktop/go.mod / desktop/go.sum 依赖固定版本,无新增或改变用户可观察能力;已由 reviewer 审查并附 matrix-exempt 标签。
  • 已运行 ./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh(validated 214 platform capabilities);MATRIX_UPDATE_EXEMPT=true ./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/main HEAD 通过。
  • 没有提交 .artifacts/ 下生成的矩阵视图。

插件归属 / Plugin ownership

  • 已在仓库根目录运行 develop-lithe 第三节“插件归属与宿主零依赖”的自查命令,结果为空。
  • 新增或修改的测试:本次未新增测试。
  • 没有为具体插件提供的能力新建或更新宿主功能矩阵条目。
  • 插件文案没有写进 shared/i18n/;插件构建资源没有写进文档。
  • [N/A] 修改了通用扩展点、可能影响已发布插件的:未修改扩展点。

UI 验证 / UI evidence

N/A:仅同步 Viva 依赖固定版本,未改动布局、控件、样式或文案。

统一日志系统 / Structured logging

N/A:未新增或修改日志事件、错误处理或降级路径。

界面文案 / i18n

  • [N/A] 宿主文案改动:未改动界面文案;已运行 node scripts/i18n/generate-i18n.mjs --check 与 node scripts/i18n/verify-app-language-localization.mjs 验证基线通过。

逻辑归属 / Logic placement

N/A:未新增或修改业务逻辑。

性能与内存 / Performance and memory

N/A:未改动启动、后台任务或渲染热路径,4 个上游提交不改变现有调用行为。

设置 / Settings

N/A:未改动设置。

插件契约 / Plugin contract

N/A:未改动 Core 或插件契约。

发行包与资源 / Bundle and resources

  • 运行时不向已安装的 app bundle 或 Windows 安装目录写入;已运行 zsh scripts/desktop/verify/verify-runtime-bundle-immutability.sh 通过。

无用代码与重构 / Dead code and refactoring

  • [N/A] 本次改动导致变成无用的代码已在本 PR 删除:无。
  • 本次之前就存在的无用代码或可重构之处:已记录存量发现(desktop/internal/pluginview/render.go:24,140 的 viva vet kept-context 提示),因仓库无 refactor 标签暂未建单(按规则不自行创建标签,将在交付报告中向用户说明)。

验证 / Verification

命令或操作 平台 结果
./scripts/desktop/desktop-go.sh test ./internal/workbench ./internal/editorview ./internal/settingswindow macOS arm64 ok(workbench 261.964s、editorview 1.135s、settingswindow 4.260s)
./scripts/desktop/desktop-go.sh test ./... macOS arm64 除 internal/localshell 外全包通过;localshell 的 /opt/homebrew/bin/bash 用例在基线 origin/main 上同样失败(outlived the closed terminal by 5s),与本 PR 无关
./scripts/desktop/desktop-go.sh vet ./... macOS arm64 通过(无输出)
./scripts/desktop/generate-desktop-icons.sh macOS arm64 与已提交 icons.go/viva_mark.go 逐字节一致(零 diff)
./scripts/desktop/generate-desktop-file-icons.sh macOS arm64 图标字节完全一致;因存量 #2141 注释头差异产生 3 行注释 diff(已还原未提交)
./scripts/desktop/desktop-go.sh --exec go run github.com/vivaui/viva/cmd/viva vet ./... macOS arm64 仅报告 2 条存量 desktop/internal/pluginview/render.go:24,140 kept-context(非本 PR 引入)
./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh macOS validated 214 platform capabilities
MATRIX_UPDATE_EXEMPT=true ./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/main HEAD macOS 通过
./scripts/agent-notes/verify-agent-notes.sh macOS ok: 184 active Agent Note(s) verified
zsh scripts/desktop/verify/verify-runtime-bundle-immutability.sh macOS passed
node scripts/i18n/generate-i18n.mjs --check & verify-app-language-localization.mjs macOS 通过(11848/11848)
插件零依赖自查 rg macOS 结果为空
Lithe-viva:go vet ./...、go test ./...(除 cmd/viva SDK 部署目标问题外全过)、GOOS=windows GOARCH=amd64/arm64 go build ./... macOS / Windows 交叉编译 通过

未能执行的检查和原因: 未在 Windows / Linux 本机实机运行桌面测试(本机为 macOS,Windows 交叉编译已在 fork 验证通过)。

提交前确认 / Final checks

  • 分支从最新的 main 创建,目标分支为 main
  • 以 Draft 提交,本地验证通过并自审后才标记 ready
  • 没有无关改动,没有提交产物或个人路径
  • 本次测试启动的进程已清理,无 Lithe 进程残留

@ghfind-review ghfind-review Bot added the review: high ghfind author score; see https://ghfind.com label Nov 20, 2026
@1lck 1lck added the matrix-exempt Reviewed non-user-visible refactor; skips platform feature matrix update label Nov 20, 2026
@1lck
1lck marked this pull request as ready for review November 20, 2026 03:13
@1lck
1lck force-pushed the chore/sync-viva-46b10fd branch from 5cfed30 to 747f820 Compare November 20, 2026 03:14
@1lck

1lck commented Nov 20, 2026

Copy link
Copy Markdown
Owner Author

PR #2220 verification note:

  • Passed CI checks: Desktop CI / Verify pins, Desktop CI / Format and script tests, Verify Platform Feature Matrix, Desktop CI / Vet and test on Linux, and Desktop CI / Vet and test on Windows.
  • Desktop CI / Vet and test on macOS failed twice on the unrelated pre-existing TestProjectTreeDirectoryReadCancelsWhenProjectCloses flake (desktop/internal/workbench/filetree_test.go:119: directory read did not start), which already reproduces on origin/main prior to the Viva sync commit 46b10fdf (see run 44554059512).
  • Local macOS verification after rebasing on origin/main passed completely: ./scripts/desktop/desktop-go.sh test -count=1 ./internal/workbench (259.317s) and -race -count=5 on TestProjectTreeDirectoryReadCancelsWhenProjectCloses (3.981s).

Squash-merging per authorization after local + cross-platform verification and filing a follow-up test bug Issue for the pre-existing filetree_test.go flake.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

matrix-exempt Reviewed non-user-visible refactor; skips platform feature matrix update review: high ghfind author score; see https://ghfind.com

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant