-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Add the potential format parameter to the invalid type issue #5370
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
WalkthroughThe Zod error handling in the core module is getting an upgrade. A new import from the checks module brings in the Pre-merge checks✅ Passed checks (3 passed)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (9)**/*.{js,jsx,ts,tsx,mjs,cjs,json}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{js,jsx,ts,tsx,mjs,cjs}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{ts,tsx}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{ts,tsx,js,jsx,mjs,cjs}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{js,mjs,ts,tsx}📄 CodeRabbit inference engine (.cursor/rules/development-setup.mdc)
Files:
**/*.{js,mjs,cjs,jsx,ts,tsx}📄 CodeRabbit inference engine (.cursor/rules/guidelines.mdc)
Files:
packages/zod/src/v4/core/errors.ts📄 CodeRabbit inference engine (.cursor/rules/zod-internals.mdc)
Files:
packages/**/src/**/*.{ts,tsx}📄 CodeRabbit inference engine (.cursor/rules/zod-project-guide.mdc)
Files:
packages/zod/**📄 CodeRabbit inference engine (.cursor/rules/zod-project-guide.mdc)
Files:
🧠 Learnings (5)📚 Learning: 2025-10-21T17:27:32.477Z
Applied to files:
📚 Learning: 2025-10-21T17:26:08.263Z
Applied to files:
📚 Learning: 2025-10-21T17:26:08.263Z
Applied to files:
📚 Learning: 2025-10-21T17:26:08.263Z
Applied to files:
📚 Learning: 2025-10-21T17:27:32.477Z
Applied to files:
🧬 Code graph analysis (1)packages/zod/src/v4/core/errors.ts (1)
🔇 Additional comments (2)
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 |
This is more of an issue than an actual fix, as I'm not familiar enough with the codebase to ensure this is valid, but I wanted to at least start with some code rather than just opening an issue.
I'm trying to declare an expected validation error, and typescript is saying it's invalid. Here's my expectation:
And the typescript compiler is returning:
error TS2353: Object literal may only specify known properties, and 'format' does not exist in type '$ZodIssueInvalidType<unknown>'.
I tried to remove the
format
property from my expectation, but it is actually included in the zod response, so I'm presuming it's not correctly declared somewhere in this codebase...