fix: lite schema validation - #2794
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughLite-compatible attributes now carry ChangesLite schema attribute preservation
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related issues
Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
packages/cli/test/ts-schema-gen.test.tsESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox. 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 |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/zod/package.json`:
- Line 53: Regenerate the root pnpm-lock.yaml after adding `@types/node` to the
package catalog dependency configuration, ensuring the lockfile records the
matching catalog entry and updated resolution. Commit the resulting lockfile
change alongside the package.json update.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 8ec1ad57-98dd-498c-906a-3f0d42c7bca6
📒 Files selected for processing (9)
packages/cli/test/ts-schema-gen.test.tspackages/language/res/stdlib.zmodelpackages/language/src/utils.tspackages/sdk/src/ts-schema-generator.tspackages/zod/package.jsonpackages/zod/test/factory.test.tspackages/zod/test/schema/schema-lite.tspackages/zod/tsconfig.jsonpackages/zod/vitest.config.ts
Fixes #2793 and #2764
Adds a new
@@@liteattribute, which specifies that an attribute should not be stripped when generating lite schemas. All validation attributes,@meta, and@@meta, are decorated with it.@defaultand@updatedAtare also decorated with because the frontend hooks rely on checking them.The Zod factory test suite now runs against both a full schema and a lite schema.
Summary by CodeRabbit
Summary by CodeRabbit
New Features
Tests