You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
反过来,用一个把测试文件包含进来的临时 tsconfig(include: ["src"],去掉 test 的 exclude)编译,断言确实会生效并报 TS2344。也就是说断言本身写得没错,只是没人跑。
为什么这条值得单独修
这个文件的自己的文件头就写着这一类失败:
…objectui#3009 —— where a guard file's own header falsely claimed its checks were "the real enforcement" for the entire interval during which nothing compiled them.
以及 scripts/check-spec-symbol-derivation.mjs 头部的:
This guard lands the rule AS THE CHECK, not as an AGENTS.md paragraph. A prose-only rule is precisely the "declared ≠ enforced" landmine…
src/console/ai/__tests__/AiChatPage.hydration.test.ts(25,16): error TS2339: Property 'toolInvocations' does not exist on type 'ChatMessage'.
src/console/ai/__tests__/deriveBoundPackageId.test.ts(20,33): error TS2345: Argument of type 'ChatMessage[]' is not assignable to parameter of type 'readonly PackageBearingMessage[]'.
src/context/__tests__/FavoritesProvider.test.tsx(165,7): error TS2578: Unused '@ts-expect-error' directive.
src/hooks/__tests__/useConsoleActionRuntime.test.tsx(464,25): error TS2339: Property 'onModal' does not exist on type '{ … }'.
src/utils/decisionOutputParams.test.ts(130,55): error TS2322: Type 'string' is not assignable to type '"user" | "text" | "position" | "team" | "department" | undefined'.
(注:spec-symbol-parity.test.ts 本身是干净的 —— 0 error。)
可选方案
最小、够用:给「以类型断言为唯一价值」的文件单独建一个 tsconfig.typetests.json(只 include 这几个 parity/tripwire 文件),在 CI 里加一步 tsc --noEmit -p。代价小,立刻把 tripwire 变成真 gate。
Activity
os-zhuang commentedon Aug 2, 2026
认领:PM 循环第 3 轮(按新升级判据:恢复不变量类——「gate 必须真的编译它声称检查的东西」——直接派发,不再请示;维护者持否决权)
分支:
claude/issue-3181-typetests-gateWorktree:
objectui-issue-3181如另有会话已在做本 issue,以更早的认领评论为准,本认领让行。
Generated by Claude Code
os-zhuang commentedon Aug 2, 2026
PM 验收:ACCEPT → PR #3187(已转正并启用 merge-when-ready,入队自动合并)。
最小路线落地且门禁自身也被钉住:专用
tsconfig.typetests.json(显式列文件不,用 glob,避免把 53/189 个既有测试类型错误扫进来)、链入既有type-check脚本从而直接进 CI 的 Type Check job(零 workflow 改动)、check-type-check-coverage.mjs增加配套棘轮——typetests 配置存在但没人跑/会 emit/不含测试文件,即硬失败。双层负向对照均实测:必假断言让新门禁 TURBO_EXIT=2(旧门禁同树 exit 0,复现 issue);撤掉链式调用让棘轮 exit 1。CI 实况已核验(Type Check job 日志可见新命令)。自此 #3185 反转的
DecisionOutputDefparity 钉子正式通电;全量修复既有测试类型错误明确不在范围内,继续由本 issue 正文与 objectstack#4118 跟踪。Generated by Claude Code
fix(app-shell): actually compile `spec-symbol-parity.test.ts`'s type …
test(react): type-check the whole test tree, and retire the narrow ty…
test(components): type-check the whole test tree, and retire the narr…
test(core,app-shell): type-check the whole test trees, retire both na…