n8n项目编译时取消类型检测,提交代码时取消校验

修改前

src/command-registry.ts:63:5 - error TS2322: Type 'FlagsSchema | undefined' is not assignable to type 'ZodObject<ZodRawShape, UnknownKeysParam, ZodTypeAny, { [x: string]: any; }, { [x: string]: any; }> | undefined'.

Type 'ZodObject<Record<string, ZodType<unknown, unknown, ZodTypeInternals\\>\>, strip>' is missing the following properties from type 'ZodObject<ZodRawShape, UnknownKeysParam, ZodTypeAny, { [x: string]: any; }, { [x: string]: any; }>': _cached, _getCached, _parse, nonstrict, and 14 more.

63 flagsSchema: commandEntry.flagsSchema,

~~~~~~~~~~~

../@n8n/backend-common/dist/cli-parser.d.ts:5:5

5 flagsSchema?: z.ZodObject<Flags>;

~~~~~~~~~~~

The expected type comes from property 'flagsSchema' which is declared here on type 'CliInput<ZodRawShape>'

src/command-registry.ts:132:13 - error TS2345: Argument of type 'FlagsSchema' is not assignable to parameter of type 'AnyZodObject'.

Type 'ZodObject<Record<string, ZodType<unknown, unknown, ZodTypeInternals\\>\>, strip>' is missing the following properties from type 'ZodObject<any, any, any, { [x: string]: any; }, { [x: string]: any; }>': _cached, _getCached, _parse, nonstrict, and 14 more.

132 .merge(flagsSchema).shape,

~~~~~~~~~~~

编译时取消类型检测

"build": "tsc -p tsconfig.build.json --noCheck && tsc-alias -p tsconfig.build.json && pnpm run build:data",
"skipLibCheck": true,

"noEmitOnError": false

git提交代码报错

lefthook v1.7.15 hook: pre-commit actionlint_check (skip) no files for inspection biome_check> Checked 1 file in 1175us. No fixes applied. prettier_check (skip) no files for inspection styles_check (skip) no matching staged files workspace_deps_check exec: "if": executable file not found in %PATH% summary: (done in 0.67 seconds) biome_check workspace_deps_check Hook process exited.

需要注释调lefthook.yml文件的所有内容

相关推荐
林恒smileZAZ39 分钟前
Vue<前端页面版本检测>
前端·javascript·vue.js
码事漫谈4 小时前
当AI开始“思考”:我们是否真的准备好了?
前端·后端
许杰小刀4 小时前
ctfshow-web文件包含(web78-web86)
android·前端·android studio
014-code4 小时前
订单超时取消与库存回滚的完整实现(延迟任务 + 状态机)
java·开发语言
lly2024065 小时前
组合模式(Composite Pattern)
开发语言
我是Superman丶5 小时前
Element UI 表格某行突出悬浮效果
前端·javascript·vue.js
恋猫de小郭5 小时前
你的代理归我了:AI 大模型恶意中间人攻击,钱包都被转走了
前端·人工智能·ai编程
游乐码5 小时前
c#泛型约束
开发语言·c#
Dontla5 小时前
go语言Windows安装教程(安装go安装Golang安装)(GOPATH、Go Modules)
开发语言·windows·golang
chushiyunen5 小时前
python rest请求、requests
开发语言·python