chore(desktop): 把 gen/schemas「该不该跟踪」从猜测改成实测结论——readiness 门禁要求目录存在+含 desktop/windows-schema.json+git 干净,取消跟踪即红(0 文件取消跟踪、0 条新规则,仅 +5 行注释) - #2293
Merged
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
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 |
DeliciousBuding
enabled auto-merge (squash)
September 3, 2026 14:53
Co-authored-by: Cursor <cursor@vectorcontrol.tech>
DeliciousBuding
force-pushed
the
chore/untrack-generated
branch
from
September 3, 2026 14:54
830aec1 to
dd2d1c3
Compare
This was referenced Sep 3, 2026
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.
一句话
round-71「不该跟踪的构建生成物」消融批的否定结论落盘:
app/desktop/src-tauri/gen/schemas/那 7 个被跟踪的生成物(共 ~830KB)不是零消费者,取消跟踪会直接打红 release-readiness 门禁;本 PR 只把.gitignore里原本那句猜测式注释("keep tracked only if CI/capabilities need them")换成实测答案,0 条新 ignore 规则、0 个文件取消跟踪(+5 行注释)。为什么值得占一个 PR
上一个批次的任务书把
gen/**当作「构建生成物、应取消跟踪」的候选,并假设「删掉会有 path-filtered 的 desktop 打包 job 兜底」。实测两条都不成立:checks.yml的desktop-linux-build是if: github.event_name == 'workflow_dispatch',release.yml的build-desktop*只在push tags: v*触发——PR 上app/desktop/**只跑frontend-desktop(vitest/lint,无 tauri build)。也就是说没有 PR 级打包兜底,误删只会在 release 时才炸。把这 5 行写进
.gitignore就地留证,是为了让下一个 agent 不必再花一整条 lane 重新推一遍。消费者证据(主机独立复核,非仅采信 lane 报告)
assert_generated_schema_clean()(main无条件调用)scripts/release/verify-tauri-package-readiness.py:87-105,569gen/schemas目录存在 + 含 ≥1 个.json+desktop-schema.json/windows-schema.json存在 +assert_git_path_clean目录级 git 干净.github/workflows/release-readiness.yml:53scripts/release/verify-tauri-package-dry.py:199,338$schema引用app/desktop/src-tauri/capabilities/default.json:2→"../gen/schemas/desktop-schema.json"head -4复核命中文件名级零消费者扫描(
acl-manifests/android-schema/linux-schema/mobile-schema/capabilities全(no hits))看似可删,但被目录级门禁覆盖:assert_git_path_clean对该目录跑git status --porcelain,任何??/D都算红。门禁与暗卷(本机 huawei-dev 实跑)
明卷:
python3 scripts/release/verify-tauri-package-readiness.py --RepoRoot .(本分支 worktree)Tauri package readiness policy OKbash /tmp/run-validate.sh <worktree>(61 条 CI validate 命令)PASS=61 FAIL=0 SKIP(merge-ref)=1bash scripts/verify/verify-commit-messages.sh origin/master HEADgit diff --check origin/master...HEADbash scripts/verify/check-secrets.sh --range "origin/master...HEAD"Secret guard passed.)git status --shortpnpm --dir app/desktop typecheck暗卷(主机独立重跑):
git rm --cached app/desktop/src-tauri/gen/schemas/linux-schema.json(挑一个文件名级零命中的文件,工作区文件保留)→ readiness rc=1:FAIL: Tauri generated schemas has untracked generated changes: ?? app/desktop/src-tauri/gen/schemas/linux-schema.json;git reset还原后 rc=0。⇒ 「取消跟踪即红」不是推断,是实测。git check-ignore -v:gen/android/Foo.java→ 命中.gitignore:84(rc=0,仍被忽略);gen/schemas/desktop-schema.json→ rc=1(没有被新注释或既有规则误吞)。未验证 / 边界(如实)
pnpm tauri dev/tauri build会重新生成gen/schemas/*" 依据的是 Tauri CLI 既有行为 + CI 内已存在的命令(checks.yml:1244用--no-bundle),本批未实跑验证。只报未做(需改构建配置或属设计决策,本批不动)
app/web/public/fonts/material-symbols-outlined.woff2与app/desktop/public/fonts/…woff2各 1,127,988B、sha256 相同;app/web/public/agenthub-icon-rounded-512.png与app/mobile-rn/assets/agenthub-splash-icon.png83,605B 相同;两份LICENSE-Apache-2.0.txt11,358B 相同。去重要改构建/打包配置,属另一批。gen/schemas内部desktop=linux=windows-schema.json(151,660B 三者逐字节相同)、android=mobile-schema.json(144,500B 相同)——Tauri 生成拓扑决定,勿人工去重。gen/schemas/capabilities.json(592B)是 CLI 对src-tauri/capabilities/default.json的生成式解析快照(≠ authored 文件),按同一目录级门禁保留。git ls-files内无dist/、target/、coverage/、.next/、其它gen/目录。