Skip to content
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

Fix scan by making zod schema strict #71

Merged
merged 6 commits into from
Oct 31, 2024
Merged

Fix scan by making zod schema strict #71

merged 6 commits into from
Oct 31, 2024

Conversation

MrOrz
Copy link
Member

@MrOrz MrOrz commented Oct 30, 2024

npm run scan omits extra fields by default, while Elasticsearch with strict mapping settings rejects such documents.

This PR adds strict() to all Zod schemas, so that npm run scan can also pick up documents with extra fields.

This PR also improves error reporting by printing deeply nested objects.

@MrOrz MrOrz self-assigned this Oct 30, 2024
@MrOrz MrOrz marked this pull request as ready for review October 31, 2024 03:55
@MrOrz MrOrz merged commit 6f388da into master Oct 31, 2024
4 checks passed
@MrOrz MrOrz deleted the fix-scan branch October 31, 2024 03:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants