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文件的所有内容

相关推荐
不会kao代码的小王2 小时前
openEuler上Docker部署Kafka消息队列实战
前端·云原生·stable diffusion·eureka
Lenyiin2 小时前
makefile
java·大数据·前端
汝生淮南吾在北2 小时前
SpringBoot+Vue非遗文化宣传网站
java·前端·vue.js·spring boot·后端·毕业设计·课程设计
谷粒.2 小时前
AI在测试中的应用:从自动化到智能化的跨越
运维·前端·网络·人工智能·测试工具·开源·自动化
斗鹰一余洛晟2 小时前
Web跨域问题
前端·状态模式
悟能不能悟2 小时前
前端如何重定向
前端
武藤一雄2 小时前
C# Prism框架详解
开发语言·后端·微软·c#·.net·wpf
毕设源码-郭学长2 小时前
【开题答辩全过程】以 基于Java的星星儿童救助帮扶系统为例,包含答辩的问题和答案
java·开发语言