next.js
580286df - Harden the dev route-miss reconciliation

Commit
5 days ago
Harden the dev route-miss reconciliation Address adversarial review findings on the previous commit: - A route deleted between watcher updates could match a stale dev matcher and fail the request with 500 instead of rendering the 404 page. Treat a PageNotFoundError from ensure as no match. - Concurrent matcher reloads (now reachable from the request path) ran unserialized; coalesce them into one running and one queued scan, and don't let a failed reload reject every subsequent request through waitTillReady. - The router 404 probe missed rewritten requests when useFileSystemPublicRoutes is disabled (gate on didRewrite), ran for /_next/* asset paths, and missed routes requested with a trailing slash. - ensurePage now re-checks the entrypoints once when its wait deadline fires, so an update landing at the deadline isn't dropped.
Author
Parents
Loading