Repository navigation
ci: check the first request after a cold nuxt dev - #1500
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
commit: |
Bundle sizeClient 774.4 kB (no change) · Server 1.59 MB No route loads 100 B more or less before it renders. No prerendered URL's initial load or HTML changes by 100 B or more. Brotli sizes. Changes under 100 B are left out of the tables. Measured by nuxt-bundle-analyzer for |
This branch was successfully deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Why
A cold
nuxt devcould leave the first request hanging:nuxt-og-image7.0.7 rebuilt Nitro right after "Ready", and Nitro 2 drops the requests in flight when it swaps its dev worker. Thenuxt-og-image7.2.0 bump in #1498 fixed it, but nothing in CI would catch a rebuild like this coming back from any module.What changed
test/dev/first-request.test.ts: it cold-startsnuxt devon the playground, requests/3 s after "Ready", and expects one Nitro build and a 200 within 30 s.devVitest project and atest:devscript.pnpm run test:devin thebuildCI job, after the unit tests.Evidence
Before (
nuxt-og-image7.0.7, onc020e49)After (
main,nuxt-og-image7.2.0)Notes
NODE_ENV,TESTandVITEST*variables for thenuxt devprocess. With them, Nuxt and Nitro run in test mode, hide their build logs, and the test passed on the broken version.playground/.nuxtandplayground/node_modules/.cachefor a cold start, which adds about 25 s to thebuildjob.ELI5
Starting the docs site locally sometimes left the first page loading forever, because a plugin restarted the server just after startup. A dependency update fixed it. This adds a test that starts the site the same way and fails if the server restarts or the first page doesn't load.
🤖 Generated with Amp, reviewed by @larbish before opening.