-
Notifications
You must be signed in to change notification settings - Fork 27.2k
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
Do not assign to readonly property in Safari #16051
Merged
Merged
Conversation
This file contains 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
Safari now treats Error#code as a readonly property, which means we can no longer override it. This PR replaces the now-reserved property with a Symbol descriptor. It also adds new production tests for this behavior to ensure they're ran against all major browsers (Safari included) in our E2E CI. --- Fixes vercel#11608
Stats from current PRDefault Server Mode (Increase detected
|
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
buildDuration | 12.6s | 12.2s | -368ms |
nodeModulesSize | 64.7 MB | 64.7 MB |
Page Load Tests Overall increase ✓
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.216 | 2.176 | -0.04 |
/ avg req/sec | 1128.2 | 1149.03 | +20.83 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.233 | 1.197 | -0.04 |
/error-in-render avg req/sec | 2027.49 | 2087.89 | +60.4 |
Client Bundles (main, webpack, commons) Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..ec1a.js gzip | 9.99 kB | 10 kB | |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-8927408..22b2.js gzip | 6.74 kB | 6.72 kB | -13 B |
webpack-ccf5..276a.js gzip | 751 B | 751 B | ✓ |
Overall change | 56.6 kB | 56.6 kB |
Client Bundles (main, webpack, commons) Modern Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 5.89 kB | 5.92 kB | |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-15cde23..dule.js gzip | 5.81 kB | 5.79 kB | -17 B |
webpack-10c7..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 51.6 kB | 51.6 kB |
Legacy Client Bundles (polyfills)
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
polyfills-75..1629.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-874bd8a..0103.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-fa39c..ec40.js gzip | 3.45 kB | 3.45 kB | ✓ |
hooks-585f07..95a3.js gzip | 887 B | 887 B | ✓ |
index-c7b63f..fc02.js gzip | 227 B | 227 B | ✓ |
link-f4d2979..e57b.js gzip | 1.29 kB | 1.29 kB | ✓ |
routerDirect..ebc7.js gzip | 284 B | 284 B | ✓ |
withRouter-2..db68.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.71 kB | 7.71 kB | ✓ |
Client Pages Modern
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-97e743e..dule.js gzip | 626 B | 626 B | ✓ |
_error-b4004..dule.js gzip | 2.3 kB | 2.3 kB | ✓ |
hooks-696209..dule.js gzip | 387 B | 387 B | ✓ |
index-a4dd74..dule.js gzip | 226 B | 226 B | ✓ |
link-653c74f..dule.js gzip | 1.26 kB | 1.26 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-1..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_buildManifest.js gzip | 273 B | 273 B | ✓ |
_buildManife..dule.js gzip | 280 B | 280 B | ✓ |
Overall change | 553 B | 553 B | ✓ |
Rendered Page Sizes Overall decrease ✓
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
index.html gzip | 948 B | 946 B | -2 B |
link.html gzip | 955 B | 952 B | -3 B |
withRouter.html gzip | 942 B | 940 B | -2 B |
Overall change | 2.85 kB | 2.84 kB | -7 B |
Diffs
Diff for 677f882d2ed8..01.module.js
@@ -537,6 +537,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
exports.delBasePath = delBasePath;
exports.isLocalURL = isLocalURL;
exports.resolveHref = resolveHref;
+ exports.markLoadingError = markLoadingError;
exports.default = void 0;
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
@@ -635,6 +636,12 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
}
}
+ var PAGE_LOAD_ERROR = Symbol("PAGE_LOAD_ERROR");
+
+ function markLoadingError(err) {
+ return Object.defineProperty(err, PAGE_LOAD_ERROR, {});
+ }
+
function prepareUrlAs(router, url, as) {
// If url and as provided as an object representation,
// we'll format them into the string version here.
@@ -690,7 +697,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
// on a client-side transition. Otherwise, we'd get into an infinite
// loop.
if (!isServerRender) {
- err.code = "PAGE_LOAD_ERROR";
+ markLoadingError(err);
}
throw err;
@@ -1085,7 +1092,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
throw err;
}
- if (err.code === "PAGE_LOAD_ERROR" || loadErrorFail) {
+ if (PAGE_LOAD_ERROR in err || loadErrorFail) {
Router.events.emit("routeChangeError", err, as); // If we can't load the page it could be one of following reasons
// 1. Page doesn't exists
// 2. Page does exist in a different zone
Diff for 677f882d2ed8..a52e0893d.js
@@ -678,6 +678,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
exports.delBasePath = delBasePath;
exports.isLocalURL = isLocalURL;
exports.resolveHref = resolveHref;
+ exports.markLoadingError = markLoadingError;
exports["default"] = void 0;
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
@@ -776,6 +777,12 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
}
}
+ var PAGE_LOAD_ERROR = Symbol("PAGE_LOAD_ERROR");
+
+ function markLoadingError(err) {
+ return Object.defineProperty(err, PAGE_LOAD_ERROR, {});
+ }
+
function prepareUrlAs(router, url, as) {
// If url and as provided as an object representation,
// we'll format them into the string version here.
@@ -833,7 +840,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
// on a client-side transition. Otherwise, we'd get into an infinite
// loop.
if (!isServerRender) {
- err.code = "PAGE_LOAD_ERROR";
+ markLoadingError(err);
}
throw err;
@@ -1400,9 +1407,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
throw err;
case 2:
- if (
- !(err.code === "PAGE_LOAD_ERROR" || loadErrorFail)
- ) {
+ if (!(PAGE_LOAD_ERROR in err || loadErrorFail)) {
_context2.next = 6;
break;
}
Diff for main-6a20493..23.module.js
@@ -1116,15 +1116,7 @@
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
- var _isDynamic = __webpack_require__("/jkW");
-
- var _routeMatcher = __webpack_require__("gguc");
-
- var _routeRegex = __webpack_require__("YTqd");
-
- var _querystring = __webpack_require__("3WeD");
-
- var _parseRelativeUrl = __webpack_require__("hS4m");
+ var _router = __webpack_require__("elyg");
var _escapePathDelimiters = _interopRequireDefault(
__webpack_require__("fcRV")
@@ -1134,7 +1126,15 @@
__webpack_require__("Lab5")
);
- var _router = __webpack_require__("elyg");
+ var _isDynamic = __webpack_require__("/jkW");
+
+ var _parseRelativeUrl = __webpack_require__("hS4m");
+
+ var _querystring = __webpack_require__("3WeD");
+
+ var _routeMatcher = __webpack_require__("gguc");
+
+ var _routeRegex = __webpack_require__("YTqd");
function hasRel(rel, link) {
try {
@@ -1144,9 +1144,9 @@
}
function pageLoadError(route) {
- var error = new Error("Error loading ".concat(route));
- error.code = "PAGE_LOAD_ERROR";
- return error;
+ return (0, _router.markLoadingError)(
+ new Error("Error loading ".concat(route))
+ );
}
var relPrefetch =
Diff for main-eeb0502..13cbe3936.js
@@ -1477,15 +1477,7 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
- var _isDynamic = __webpack_require__("/jkW");
-
- var _routeMatcher = __webpack_require__("gguc");
-
- var _routeRegex = __webpack_require__("YTqd");
-
- var _querystring = __webpack_require__("3WeD");
-
- var _parseRelativeUrl = __webpack_require__("hS4m");
+ var _router = __webpack_require__("elyg");
var _escapePathDelimiters = _interopRequireDefault(
__webpack_require__("fcRV")
@@ -1495,7 +1487,15 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
__webpack_require__("Lab5")
);
- var _router = __webpack_require__("elyg");
+ var _isDynamic = __webpack_require__("/jkW");
+
+ var _parseRelativeUrl = __webpack_require__("hS4m");
+
+ var _querystring = __webpack_require__("3WeD");
+
+ var _routeMatcher = __webpack_require__("gguc");
+
+ var _routeRegex = __webpack_require__("YTqd");
function hasRel(rel, link) {
try {
@@ -1505,9 +1505,9 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
}
function pageLoadError(route) {
- var error = new Error("Error loading ".concat(route));
- error.code = "PAGE_LOAD_ERROR";
- return error;
+ return (0, _router.markLoadingError)(
+ new Error("Error loading ".concat(route))
+ );
}
var relPrefetch =
Diff for index.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ href="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -81,13 +81,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-eeb050234ea13cbe3936.js"
+ src="/_next/static/chunks/main-90ab0b721012dc5f9113.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ src="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -117,13 +117,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Diff for link.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ href="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -86,13 +86,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-eeb050234ea13cbe3936.js"
+ src="/_next/static/chunks/main-90ab0b721012dc5f9113.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ src="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -122,13 +122,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Diff for withRouter.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ href="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -81,13 +81,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-eeb050234ea13cbe3936.js"
+ src="/_next/static/chunks/main-90ab0b721012dc5f9113.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-6a2049350a56eb766c23.module.js"
+ src="/_next/static/chunks/main-0c971b4b4e406f68741b.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -117,13 +117,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
buildDuration | 14.1s | 14.2s | |
nodeModulesSize | 64.7 MB | 64.7 MB |
Client Bundles (main, webpack, commons) Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..ec1a.js gzip | 9.99 kB | N/A | N/A |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-8927408..22b2.js gzip | 6.74 kB | N/A | N/A |
webpack-ccf5..276a.js gzip | 751 B | 751 B | ✓ |
677f882d2ed8..6aa6.js gzip | N/A | 10 kB | N/A |
main-26a2edd..9a33.js gzip | N/A | 6.72 kB | N/A |
Overall change | 56.6 kB | 56.6 kB |
Client Bundles (main, webpack, commons) Modern Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 5.89 kB | N/A | N/A |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-15cde23..dule.js gzip | 5.81 kB | N/A | N/A |
webpack-10c7..dule.js gzip | 751 B | 751 B | ✓ |
677f882d2ed8..dule.js gzip | N/A | 5.92 kB | N/A |
main-ef93004..dule.js gzip | N/A | 5.79 kB | N/A |
Overall change | 51.6 kB | 51.6 kB |
Legacy Client Bundles (polyfills)
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
polyfills-75..1629.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-874bd8a..0103.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-fa39c..ec40.js gzip | 3.45 kB | 3.45 kB | ✓ |
hooks-585f07..95a3.js gzip | 887 B | 887 B | ✓ |
index-c7b63f..fc02.js gzip | 227 B | 227 B | ✓ |
link-f4d2979..e57b.js gzip | 1.29 kB | 1.29 kB | ✓ |
routerDirect..ebc7.js gzip | 284 B | 284 B | ✓ |
withRouter-2..db68.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.71 kB | 7.71 kB | ✓ |
Client Pages Modern
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-97e743e..dule.js gzip | 626 B | 626 B | ✓ |
_error-b4004..dule.js gzip | 2.3 kB | 2.3 kB | ✓ |
hooks-696209..dule.js gzip | 387 B | 387 B | ✓ |
index-a4dd74..dule.js gzip | 226 B | 226 B | ✓ |
link-653c74f..dule.js gzip | 1.26 kB | 1.26 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-1..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_buildManifest.js gzip | 273 B | 273 B | ✓ |
_buildManife..dule.js gzip | 280 B | 280 B | ✓ |
Overall change | 553 B | 553 B | ✓ |
Serverless bundles Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_error.js | 1.03 MB | 1.03 MB | ✓ |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.82 kB | 3.82 kB | ✓ |
index.js | 1.03 MB | 1.03 MB | ✓ |
link.js | 1.07 MB | 1.07 MB | |
routerDirect.js | 1.06 MB | 1.06 MB | |
withRouter.js | 1.06 MB | 1.06 MB | |
Overall change | 5.26 MB | 5.26 MB |
ijjk
approved these changes
Aug 10, 2020
Stats from current PRDefault Server Mode (Increase detected
|
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
buildDuration | 13.7s | 13.4s | -214ms |
nodeModulesSize | 57.2 MB | 57.2 MB |
Page Load Tests Overall increase ✓
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.678 | 2.597 | -0.08 |
/ avg req/sec | 933.4 | 962.71 | +29.31 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.69 | 1.7 | |
/error-in-render avg req/sec | 1479.21 | 1471.01 |
Client Bundles (main, webpack, commons) Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..ec1a.js gzip | 9.99 kB | 10 kB | |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-d0ad4d2..1557.js gzip | 6.74 kB | 6.72 kB | -12 B |
webpack-ccf5..276a.js gzip | 751 B | 751 B | ✓ |
Overall change | 56.6 kB | 56.6 kB |
Client Bundles (main, webpack, commons) Modern Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 5.89 kB | 5.92 kB | |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-1a596b6..dule.js gzip | 5.81 kB | 5.79 kB | -16 B |
webpack-10c7..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 51.6 kB | 51.6 kB |
Legacy Client Bundles (polyfills)
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
polyfills-75..1629.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-874bd8a..0103.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-fa39c..ec40.js gzip | 3.45 kB | 3.45 kB | ✓ |
hooks-585f07..95a3.js gzip | 887 B | 887 B | ✓ |
index-c7b63f..fc02.js gzip | 227 B | 227 B | ✓ |
link-f4d2979..e57b.js gzip | 1.29 kB | 1.29 kB | ✓ |
routerDirect..ebc7.js gzip | 284 B | 284 B | ✓ |
withRouter-2..db68.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.71 kB | 7.71 kB | ✓ |
Client Pages Modern
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-97e743e..dule.js gzip | 626 B | 626 B | ✓ |
_error-b4004..dule.js gzip | 2.3 kB | 2.3 kB | ✓ |
hooks-696209..dule.js gzip | 387 B | 387 B | ✓ |
index-a4dd74..dule.js gzip | 226 B | 226 B | ✓ |
link-653c74f..dule.js gzip | 1.26 kB | 1.26 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-1..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_buildManifest.js gzip | 273 B | 273 B | ✓ |
_buildManife..dule.js gzip | 280 B | 280 B | ✓ |
Overall change | 553 B | 553 B | ✓ |
Rendered Page Sizes Overall decrease ✓
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
index.html gzip | 947 B | 945 B | -2 B |
link.html gzip | 952 B | 953 B | |
withRouter.html gzip | 940 B | 940 B | ✓ |
Overall change | 2.84 kB | 2.84 kB | -1 B |
Diffs
Diff for 677f882d2ed8..01.module.js
@@ -537,6 +537,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
exports.delBasePath = delBasePath;
exports.isLocalURL = isLocalURL;
exports.resolveHref = resolveHref;
+ exports.markLoadingError = markLoadingError;
exports.default = void 0;
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
@@ -635,6 +636,12 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
}
}
+ var PAGE_LOAD_ERROR = Symbol("PAGE_LOAD_ERROR");
+
+ function markLoadingError(err) {
+ return Object.defineProperty(err, PAGE_LOAD_ERROR, {});
+ }
+
function prepareUrlAs(router, url, as) {
// If url and as provided as an object representation,
// we'll format them into the string version here.
@@ -690,7 +697,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
// on a client-side transition. Otherwise, we'd get into an infinite
// loop.
if (!isServerRender) {
- err.code = "PAGE_LOAD_ERROR";
+ markLoadingError(err);
}
throw err;
@@ -1085,7 +1092,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
throw err;
}
- if (err.code === "PAGE_LOAD_ERROR" || loadErrorFail) {
+ if (PAGE_LOAD_ERROR in err || loadErrorFail) {
Router.events.emit("routeChangeError", err, as); // If we can't load the page it could be one of following reasons
// 1. Page doesn't exists
// 2. Page does exist in a different zone
Diff for 677f882d2ed8..a52e0893d.js
@@ -678,6 +678,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
exports.delBasePath = delBasePath;
exports.isLocalURL = isLocalURL;
exports.resolveHref = resolveHref;
+ exports.markLoadingError = markLoadingError;
exports["default"] = void 0;
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
@@ -776,6 +777,12 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
}
}
+ var PAGE_LOAD_ERROR = Symbol("PAGE_LOAD_ERROR");
+
+ function markLoadingError(err) {
+ return Object.defineProperty(err, PAGE_LOAD_ERROR, {});
+ }
+
function prepareUrlAs(router, url, as) {
// If url and as provided as an object representation,
// we'll format them into the string version here.
@@ -833,7 +840,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
// on a client-side transition. Otherwise, we'd get into an infinite
// loop.
if (!isServerRender) {
- err.code = "PAGE_LOAD_ERROR";
+ markLoadingError(err);
}
throw err;
@@ -1400,9 +1407,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
throw err;
case 2:
- if (
- !(err.code === "PAGE_LOAD_ERROR" || loadErrorFail)
- ) {
+ if (!(PAGE_LOAD_ERROR in err || loadErrorFail)) {
_context2.next = 6;
break;
}
Diff for main-20849c6..1a6927331.js
@@ -1477,15 +1477,7 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
- var _isDynamic = __webpack_require__("/jkW");
-
- var _routeMatcher = __webpack_require__("gguc");
-
- var _routeRegex = __webpack_require__("YTqd");
-
- var _querystring = __webpack_require__("3WeD");
-
- var _parseRelativeUrl = __webpack_require__("hS4m");
+ var _router = __webpack_require__("elyg");
var _escapePathDelimiters = _interopRequireDefault(
__webpack_require__("fcRV")
@@ -1495,7 +1487,15 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
__webpack_require__("Lab5")
);
- var _router = __webpack_require__("elyg");
+ var _isDynamic = __webpack_require__("/jkW");
+
+ var _parseRelativeUrl = __webpack_require__("hS4m");
+
+ var _querystring = __webpack_require__("3WeD");
+
+ var _routeMatcher = __webpack_require__("gguc");
+
+ var _routeRegex = __webpack_require__("YTqd");
function hasRel(rel, link) {
try {
@@ -1505,9 +1505,9 @@ _N_E = (window["webpackJsonp_N_E"] = window["webpackJsonp_N_E"] || []).push([
}
function pageLoadError(route) {
- var error = new Error("Error loading ".concat(route));
- error.code = "PAGE_LOAD_ERROR";
- return error;
+ return (0, _router.markLoadingError)(
+ new Error("Error loading ".concat(route))
+ );
}
var relPrefetch =
Diff for main-7d2b9d2..b1.module.js
@@ -1116,15 +1116,7 @@
var _mitt = _interopRequireDefault(__webpack_require__("dZ6Y"));
- var _isDynamic = __webpack_require__("/jkW");
-
- var _routeMatcher = __webpack_require__("gguc");
-
- var _routeRegex = __webpack_require__("YTqd");
-
- var _querystring = __webpack_require__("3WeD");
-
- var _parseRelativeUrl = __webpack_require__("hS4m");
+ var _router = __webpack_require__("elyg");
var _escapePathDelimiters = _interopRequireDefault(
__webpack_require__("fcRV")
@@ -1134,7 +1126,15 @@
__webpack_require__("Lab5")
);
- var _router = __webpack_require__("elyg");
+ var _isDynamic = __webpack_require__("/jkW");
+
+ var _parseRelativeUrl = __webpack_require__("hS4m");
+
+ var _querystring = __webpack_require__("3WeD");
+
+ var _routeMatcher = __webpack_require__("gguc");
+
+ var _routeRegex = __webpack_require__("YTqd");
function hasRel(rel, link) {
try {
@@ -1144,9 +1144,9 @@
}
function pageLoadError(route) {
- var error = new Error("Error loading ".concat(route));
- error.code = "PAGE_LOAD_ERROR";
- return error;
+ return (0, _router.markLoadingError)(
+ new Error("Error loading ".concat(route))
+ );
}
var relPrefetch =
Diff for index.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ href="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -81,13 +81,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-20849c6db7a1a6927331.js"
+ src="/_next/static/chunks/main-3cef5ecdeeb9851a5911.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ src="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -117,13 +117,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Diff for link.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ href="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -86,13 +86,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-20849c6db7a1a6927331.js"
+ src="/_next/static/chunks/main-3cef5ecdeeb9851a5911.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ src="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -122,13 +122,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Diff for withRouter.html
@@ -6,7 +6,7 @@
<meta name="next-head-count" content="2" />
<link
rel="preload"
- href="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ href="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -24,7 +24,7 @@
/>
<link
rel="preload"
- href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ href="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
as="script"
crossorigin="anonymous"
/>
@@ -81,13 +81,13 @@
src="/_next/static/chunks/polyfills-f73ba3fc145972ef83e9.js"
></script>
<script
- src="/_next/static/chunks/main-20849c6db7a1a6927331.js"
+ src="/_next/static/chunks/main-3cef5ecdeeb9851a5911.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/main-7d2b9d28b95d7efa6cb1.module.js"
+ src="/_next/static/chunks/main-610ace3a0296824e37ee.module.js"
async=""
crossorigin="anonymous"
type="module"
@@ -117,13 +117,13 @@
type="module"
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.2e522db0023a52e0893d.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.25e748ff47129ff1dba4.js"
async=""
crossorigin="anonymous"
nomodule=""
></script>
<script
- src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.0a0ebfbd41e8343f0e01.module.js"
+ src="/_next/static/chunks/677f882d2ed86fa3467b8979053c1a4c3f8bc4df.6e957134ad87644bd4a6.module.js"
async=""
crossorigin="anonymous"
type="module"
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
buildDuration | 15.7s | 15.5s | -186ms |
nodeModulesSize | 57.2 MB | 57.2 MB |
Client Bundles (main, webpack, commons) Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..ec1a.js gzip | 9.99 kB | N/A | N/A |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-d0ad4d2..1557.js gzip | 6.74 kB | N/A | N/A |
webpack-ccf5..276a.js gzip | 751 B | 751 B | ✓ |
677f882d2ed8..6aa6.js gzip | N/A | 10 kB | N/A |
main-0ee85b5..9240.js gzip | N/A | 6.72 kB | N/A |
Overall change | 56.6 kB | 56.6 kB |
Client Bundles (main, webpack, commons) Modern Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 5.89 kB | N/A | N/A |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
main-1a596b6..dule.js gzip | 5.81 kB | N/A | N/A |
webpack-10c7..dule.js gzip | 751 B | 751 B | ✓ |
677f882d2ed8..dule.js gzip | N/A | 5.92 kB | N/A |
main-d295757..dule.js gzip | N/A | 5.79 kB | N/A |
Overall change | 51.6 kB | 51.6 kB |
Legacy Client Bundles (polyfills)
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
polyfills-75..1629.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-874bd8a..0103.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-fa39c..ec40.js gzip | 3.45 kB | 3.45 kB | ✓ |
hooks-585f07..95a3.js gzip | 887 B | 887 B | ✓ |
index-c7b63f..fc02.js gzip | 227 B | 227 B | ✓ |
link-f4d2979..e57b.js gzip | 1.29 kB | 1.29 kB | ✓ |
routerDirect..ebc7.js gzip | 284 B | 284 B | ✓ |
withRouter-2..db68.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.71 kB | 7.71 kB | ✓ |
Client Pages Modern
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_app-97e743e..dule.js gzip | 626 B | 626 B | ✓ |
_error-b4004..dule.js gzip | 2.3 kB | 2.3 kB | ✓ |
hooks-696209..dule.js gzip | 387 B | 387 B | ✓ |
index-a4dd74..dule.js gzip | 226 B | 226 B | ✓ |
link-653c74f..dule.js gzip | 1.26 kB | 1.26 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-1..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_buildManifest.js gzip | 273 B | 273 B | ✓ |
_buildManife..dule.js gzip | 280 B | 280 B | ✓ |
Overall change | 553 B | 553 B | ✓ |
Serverless bundles Overall increase ⚠️
vercel/next.js canary | Timer/next.js hotfix/11608 | Change | |
---|---|---|---|
_error.js | 1.03 MB | 1.03 MB | ✓ |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.82 kB | 3.82 kB | ✓ |
index.js | 1.03 MB | 1.03 MB | ✓ |
link.js | 1.07 MB | 1.07 MB | |
routerDirect.js | 1.06 MB | 1.06 MB | |
withRouter.js | 1.06 MB | 1.06 MB | |
Overall change | 5.26 MB | 5.26 MB |
Awesome thanks |
This was fixed in |
I can confirm the error isn't raised anymore on Safari/IE11/Edge ! Thanks a lot 🙏 |
This was referenced Jun 26, 2021
This was referenced Sep 17, 2021
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Safari now treats
Error#code
as a readonly property, which means we can no longer override it.This PR replaces the now-reserved property with a Symbol descriptor.
It also adds new production tests for this behavior to ensure they're ran against all major browsers (Safari included) in our E2E CI.
Fixes #11608