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

相关推荐
Sarvartha13 小时前
数组基础知识
java·开发语言
泡海椒13 小时前
金融报表开发:jquick-pdf K 线图 PDF 可视化解决方案
java·开发语言·金融·pdf
CopyCode13 小时前
我排查了一下午,发现项目打包体积翻倍的元凶是它
前端·性能优化
孙启超13 小时前
【AI开发之Rust】第 17 课:项目总览与核心架构 —— AI 助手 Rust 核心从 0 到 1
开发语言·后端·rust
u01110267513 小时前
Vue 3 实现图片裁剪框:拖动、缩放与固定宽高比
前端·javascript·vue.js
码匠许师傅14 小时前
【C++三方组件】Asio 上篇:回调式 TCP 客户端与服务端
开发语言·c++·tcp/ip
汉堡大王952714 小时前
一张图三句需求,我用 Trae Work 做了一块能看日出日落和月相的天文机械表
前端·后端·github
神仙别闹14 小时前
基于C语言实现 TINY+ 编译器
c语言·开发语言·数据库
Wang's Blog14 小时前
Java 项目实战: 外卖平台优化-从库Slave配置与主从复制验证
java·开发语言
小小善后师14 小时前
用 Canvas + AI 实现登录页的 Logo 粒子动画
前端·vue.js