-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Upgrade to Zod 4 #14956
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
Merged
Upgrade to Zod 4 #14956
Changes from all commits
Commits
Show all changes
93 commits
Select commit
Hold shift + click to select a range
9277fbd
feat: upgrade to Zod v4
matthewp 0318297
Remove Zod v3 support, keep only v4
matthewp 0bb5419
Finish upgrade
matthewp c78a21e
Merge branch 'next' into zod4-m
matthewp 9fdfe72
skip these tests for now
matthewp be4e226
skip this one too
matthewp 11766e1
correct mark the received item
matthewp beb8c67
fix config-validate tests
matthewp 45b6c46
Merge branch 'next' into zod4-m
matthewp 085e663
merge: resolve conflicts between zod4-m and next
matthewp 19a3c1b
fix remaining build error
matthewp 94f42c1
remove references to zod4 thing
matthewp 86b54be
fixes
matthewp 59e5cdf
prevent the crash
matthewp bb8f885
switch to the native zod to json schema
matthewp 1ae84f2
oops
matthewp 8084da5
fix content layer tests
matthewp 62edc31
fix error map tests
matthewp ef994e5
fix actions test
matthewp 4f005eb
fix intellisense tsts
matthewp 2ddd549
fix schema test
matthewp 215afa0
fix: types
florian-lefebvre 3a61f4e
Update Svelte to exactly 5.43.8 in package and fixtures
matthewp 713cb7e
fix svelte tests
matthewp 8c429bc
fix more e2e
matthewp 725859f
fix cloudflare tests
matthewp bfe74e8
fix defineMiddleware issue
matthewp 530e2e0
remove unused reference
matthewp c51a23a
fix examples types
matthewp dcb3bdc
pr comment stuff
matthewp af68956
changeset
matthewp fcdf90d
remove experiemental flag
matthewp afd6528
add some debugging here
matthewp 0f181c3
remove debugging stuff
matthewp 7db7f57
Update packages/astro/src/actions/vite-plugin-actions.ts
matthewp b4a5b6b
fix
matthewp 5301b0b
fix: import
florian-lefebvre a2e44cf
use zod/v4 imports in core
matthewp 8c22939
Merge branch 'zod4-m' of github.com:withastro/astro into zod4-m
matthewp fe6659d
remove createDefineAction
matthewp 9fe4f6b
remove unnecessary type alias
matthewp 50ed91d
remove unused z4reference
matthewp 73fa08d
rename stuff
matthewp 4e90dae
unskip tests
matthewp 2f4823f
rename back to createImage
matthewp a0099f4
nit
matthewp 3e85a19
revert markdown change
matthewp f9caab6
put errorMap name back
matthewp c951ce2
address feedback on rss
matthewp 58b6fc8
Merge branch 'next' into zod4-m
florian-lefebvre eb52371
fix: exports
florian-lefebvre 7f760fa
Update packages/astro-rss/src/index.ts
matthewp dd9eadb
Update packages/astro-rss/src/schema.ts
matthewp 8c18e1e
Update packages/astro-rss/src/util.ts
matthewp 12485ed
Update packages/astro/src/assets/fonts/config.ts
matthewp 1e084d2
Update packages/astro/src/assets/fonts/types.ts
matthewp bd8aecf
Update packages/astro/src/content/loaders/types.ts
matthewp fc02d97
Update packages/astro/src/content/config.ts
matthewp 2d8ea90
Update packages/astro/src/core/config/schemas/relative.ts
matthewp 16843f6
Update packages/astro/test/units/config/config-validate.test.js
matthewp c618507
Update packages/astro/test/units/actions/form-data-to-object.test.js
matthewp 0422b86
Update packages/astro/src/core/config/schemas/refined.ts
matthewp d8ede75
Update packages/astro/src/content/content-layer.ts
matthewp e34b316
Update packages/astro/src/content/types-generator.ts
matthewp a70b1fc
Update packages/astro/src/content/utils.ts
matthewp 7edf39c
Use $ZodError
matthewp df3795b
Update packages/astro/src/core/csp/config.ts
matthewp 89692d3
fix the build
matthewp 219d2cb
Merge branch 'zod4-m' of github.com:withastro/astro into zod4-m
matthewp 1f422e3
fix e2e test
matthewp c64836d
replace z4 with z
matthewp be58ac5
increase vercel test timeout
matthewp 3570d2a
pr comments
matthewp c346cb4
export ImageFunction
matthewp 11b3dc1
use prefault
matthewp f6bfd6c
Validate experimental features special
matthewp d10cb61
bring back old locales
matthewp 31c612a
fix test
matthewp 50919d4
db needs to be a patch too
matthewp f149f99
fix chainability of image
matthewp 528f6f1
Merge branch 'next' into zod4-m
matthewp f55cfcb
update zod imports
florian-lefebvre 2a4b1da
Discard changes to packages/integrations/svelte/package.json
florian-lefebvre dfac302
Discard changes to packages/integrations/svelte/test/fixtures/async-r…
florian-lefebvre 9d03430
refresh lockfile
florian-lefebvre c35609b
chore: changeset
florian-lefebvre 82f1de6
fix: reference()
florian-lefebvre 787325d
skip broken svelte test
matthewp 1e3ac98
Update .changeset/dance-ornate-keen.md
matthewp 4de6372
Merge branch 'next' into zod4-m
florian-lefebvre 357480d
Merge branch 'next' into zod4-m
florian-lefebvre 64f1796
fix config vlaidate test
matthewp 93acc31
Merge branch 'next' into zod4-m
matthewp File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| --- | ||
| '@astrojs/sitemap': patch | ||
| '@astrojs/rss': patch | ||
| '@astrojs/db': patch | ||
| --- | ||
|
|
||
| Updates usage of zod to own dependency rather than relying on `astro/zod` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| 'astro': major | ||
| --- | ||
|
|
||
| Astro v6.0 upgrades to Zod v4 for schema validation - ([v6 upgrade guidance](https://v6.docs.astro.build/en/guides/upgrade-to/v6/#zod-4)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.