Commit graph

1069 commits

Author SHA1 Message Date
vercel-release-bot
799e6ca65a v13.5.7-canary.17 2023-10-23 18:13:11 +00:00
vercel-release-bot
dc88b413f8 v13.5.7-canary.16 2023-10-23 03:07:00 +00:00
Donny/강동윤
652a553a13
Update swc_core to v0.86.10 (#57121)
### What?

Update SWC crates. This PR fixes a regression of `swc_core`.
The important PR: https://github.com/swc-project/swc/pull/8153

### Why?

There was a regression in `swc_core`.

### How?

-  Fixes #56408

Closes WEB-1811

---------

Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2023-10-23 05:01:31 +02:00
Tobias Koppers
b64c0426bc
update turbopack (#57176)
* https://github.com/vercel/turbo/pull/6241 <!-- Tobias Koppers - make
the daily ci faster -->
* https://github.com/vercel/turbo/pull/6242 <!-- Justin Ridgewell - Add
caching to `chunk_content`'s graph walking -->
* https://github.com/vercel/turbo/pull/6228 <!-- Tobias Koppers - Reduce
resolve and resolving tasks -->
* https://github.com/vercel/turbo/pull/6244 <!-- Tobias Koppers - avoid
cloning list -->
* https://github.com/vercel/turbo/pull/6246 <!-- Tobias Koppers - fix
symlink handling -->

Closes WEB-1819
2023-10-23 02:42:29 +02:00
vercel-release-bot
2762511796 v13.5.7-canary.15 2023-10-22 23:22:41 +00:00
vercel-release-bot
e5c082418d v13.5.7-canary.14 2023-10-21 23:23:17 +00:00
Leah
0d2edbb23f
chore: move layer from chunking context to asset context (#57149)
The asset context is a better place to store the layer, because it's
affected by transitions unlike the chunking context

This PR also removes a bunch of unused code

### Why?

See https://github.com/vercel/turbo/pull/6237 for the rationale
Also needs to wait for that PR to be merged

Closes NEXT-1814

#### Turbopack Changes
* https://github.com/vercel/turbo/pull/6237 <!-- Leah - chore: move
layer from chunking context to asset context -->

---------

Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
2023-10-21 02:05:00 +02:00
vercel-release-bot
d0a1199a36 v13.5.7-canary.13 2023-10-20 23:23:41 +00:00
Steven
4d31506960
Revert "Add retry for fetching subsetted Google Fonts" (#57154)
Reverts vercel/next.js#56583 due to missing dependency

```
app/layout.jsx
An error occured in 'next/font'.
Error: Cannot find module 'async-retry'
Require stack:
- node_modules/•pnpm/next@13.5.7-canary.12_react-dom@18.2.0_react@18.2.0/node_modules/next/dist/compiled/@next/font/dist/google/retry.js
- node_modules/-pnpm/next@13.5.7-canary-12_react-dom@18.2.0_react@18.2.0/node_modules/next/dist/compiled/@next/font/dist/google/fetch-css-from-google-fonts.js
```
2023-10-20 22:14:24 +00:00
Balázs Orbán
2277797dc2
chore: drop form-data (#57141)
### What?

Dropping `form-data` polyfill as Node.js 18+ versions all expose it on `globalThis`

### Why?

Reduce the amount of shipped code in Next.js

### How?

Similar to #56899

See: https://nodejs.org/docs/latest-v18.x/api/globals.html#class-formdata
2023-10-20 19:25:42 +00:00
Tobias Koppers
4a75e71d25
prefer Option<Vc<IssueSource>> over Vc<OptionIssueSource> (#57104)
### What?

see https://github.com/vercel/turbo/pull/6229

### Why?

### How?


Closes WEB-1808
2023-10-20 18:06:23 +00:00
Josh Story
920a7e8ba6
Update React from a41957507 to d803f519e (#57015)
## React upstream Changes

- https://github.com/facebook/react/pull/27542
- https://github.com/facebook/react/pull/27551
- https://github.com/facebook/react/pull/27537
- https://github.com/facebook/react/pull/27549
- https://github.com/facebook/react/pull/27544
- https://github.com/facebook/react/pull/27543
- https://github.com/facebook/react/pull/27541
- https://github.com/facebook/react/pull/27538
- https://github.com/facebook/react/pull/27536
2023-10-20 17:42:27 +00:00
vercel-release-bot
2b60475c2b v13.5.7-canary.12 2023-10-20 17:19:41 +00:00
berlysia
c84f5ed794
Add retry for fetching subsetted Google Fonts (#56583)
### What?
Add the same re-retrieval process for subseted font files of Google Font as for CSS files.

+ make use of [async-retry](https://github.com/vercel/async-retry)

### Why?
It was reported in #45080 that Japanese fonts such as Noto Sans JP were frequently `Failed to fetch`.
A retry process was added in #51890, but it did not resolve the issue completely ( https://github.com/vercel/next.js/pull/51890#issuecomment-1614558064 ).

Here is my reproduction code with 13.5.5-canary.4 (please run locally).
https://stackblitz.com/edit/stackblitz-starters-n8zxlq?file=app%2Fpage.tsx

<details>
<summary>And my local error log is here(folded)</summary>

```
$ npm run -- dev

> nextjs@0.1.0 dev
> next dev

 ⚠ Port 3000 is in use, trying 3001 instead.
  ▲ Next.js 13.5.5-canary.4
  - Local:        http://localhost:3001

 ✓ Ready in 23.9s
 ○ Compiling /page ...
FetchError: request to https://fonts.gstatic.com/s/notosansjp/v52/-F6jfjtqLzI2JPCgQBnw7HFyzSD-AsregP8VFBEj757Y0rw_qMHVdbR2L8Y9QTJ1LwkRmR5GprQAe69m.4.woff2 failed, reason: 
    at ClientRequest.<anonymous> (/mnt/c/Users/berlysia/Downloads/stackblitz-starters-n8zxlq/node_modules/next/dist/compiled/node-fetch/index.js:1:65756)
    at ClientRequest.emit (node:events:514:28)
    at TLSSocket.socketErrorListener (node:_http_client:495:9)
    at TLSSocket.emit (node:events:514:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  type: 'system',
  errno: 'ETIMEDOUT',
  code: 'ETIMEDOUT'
}
 ⨯ Failed to download `Noto Sans JP` from Google Fonts. Using fallback font instead.

Failed to fetch `Noto Sans JP` from Google Fonts.}
FetchError: request to https://fonts.gstatic.com/s/notosansjp/v52/-F6jfjtqLzI2JPCgQBnw7HFyzSD-AsregP8VFBEj757Y0rw_qMHVdbR2L8Y9QTJ1LwkRmR5GprQAe69m.28.woff2 failed, reason: 
    at ClientRequest.<anonymous> (/mnt/c/Users/berlysia/Downloads/stackblitz-starters-n8zxlq/node_modules/next/dist/compiled/node-fetch/index.js:1:65756)
    at ClientRequest.emit (node:events:514:28)
    at TLSSocket.socketErrorListener (node:_http_client:495:9)
    at TLSSocket.emit (node:events:514:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at processTicksAndRejections (node:internal/process/task_queues:82:21)
    at runNextTicks (node:internal/process/task_queues:64:3)
    at listOnTimeout (node:internal/timers:540:9)
    at process.processTimers (node:internal/timers:514:7) {
  type: 'system',
  errno: 'ETIMEDOUT',
  code: 'ETIMEDOUT'
}
...(15 errors emitted)
```
</details>

I've found that the issue is not limited to fetching CSS, fetching subset font files is also failing.
By adding retry handling to the fetch of individual subseted font files as well, I (almost) never see `Failed to fetch` anymore.

The issue tends to become more apparent when downloading a larger number of subsetted fonts.
This suggests that the problem is more likely to occur with larger fonts, such as those designed for CJK languages.

### How?
Add the same re-retrieval process for subseted font files of Google Font as for CSS files.


Related to #51890 #53239 #45080 #53279
2023-10-20 17:10:53 +00:00
Jiachi Liu
5d6592d895
Upgrade edge-runtime/cookies (#57124)
Backport fix on 13.5.6 to canary

x-ref: #57021
2023-10-20 13:56:04 +00:00
vercel-release-bot
e437f72662 v13.5.7-canary.11 2023-10-19 23:22:57 +00:00
vercel-release-bot
143d79f733 v13.5.7-canary.10 2023-10-19 22:41:38 +00:00
vercel-release-bot
ed6b60c55a v13.5.7-canary.9 2023-10-19 19:15:58 +00:00
Jiachi Liu
a6aae865c4
Bump packages version to match canary versions (#57071)
We released 13.5.6 as stable patch, need to bump the canary version
higher than stable to match the semantics
2023-10-19 12:09:06 -07:00
Balázs Orbán
4c46ddd92a
chore: drop undici (#56899)
### What?

Note: This is not a breaking change, just removing some unused code.

### Why?

Since #56896 we don't need this, as Node.js 18+ has `fetch` exposed by default.

### How?

Depends on #56896, #56909

We already didn't load `fetch` if `globalThis` had it (ie. Node.js 18+ environments), and since we are dropping support for Node.js 16, these code paths should have no effect on runtime behavior.
2023-10-19 18:35:12 +00:00
Balázs Orbán
33db463fe4
chore: upgrade jest (#56909)
### What?

Upgrade jest to its latest version

### Why?

#56899 fails because historically Jest stripped the globals in Node.js, but 28+ isn't doing that anymore. If we upgrade, we don't have to keep track of Node.js globals and when they are added. This will be useful in removing even more polyfills for things that are natively shipped in Node.js now.

### How?

Jest 29 introduced a change to the snapshot format: https://jestjs.io/blog/2022/08/25/jest-29

First, I tried setting the old compat option to not require updating snapshots, but some tests were still failing: https://dev.azure.com/nextjs/next.js/_build/results?buildId=70633&view=logs&j=8af7cf9c-43a1-584d-6f5c-57bad8880974&t=7ae70e63-3625-50f4-6764-5b3e72b4bd7a&l=273 So going through the pain now instead.
2023-10-19 17:38:24 +00:00
vercel-release-bot
dc7bc70d4d v13.5.6-canary.8 2023-10-19 16:49:59 +00:00
vercel-release-bot
4c2b34ea7c v13.5.6-canary.7 2023-10-18 23:24:25 +00:00
vercel-release-bot
2c8606e596 v13.5.6-canary.6 2023-10-18 06:59:43 +00:00
Zack Tanner
975c999451
Update React from 09fbee89d to a41957507 (#56970)
Update React from from 09fbee89d to a41957507.

### React upstream changes

- https://github.com/facebook/react/pull/27472
- https://github.com/facebook/react/pull/27512
- https://github.com/facebook/react/pull/27509
- https://github.com/facebook/react/pull/27517
- https://github.com/facebook/react/pull/27523
- https://github.com/facebook/react/pull/27516
- https://github.com/facebook/react/pull/27505
2023-10-18 01:15:55 +00:00
vercel-release-bot
318cbbf9b1 v13.5.6-canary.5 2023-10-17 23:22:33 +00:00
vercel-release-bot
f19dabbc6d v13.5.6-canary.4 2023-10-17 21:22:19 +00:00
vercel-release-bot
df1d4a16aa v13.5.6-canary.3 2023-10-17 16:36:35 +00:00
vercel-release-bot
ee9bee96af v13.5.6-canary.2 2023-10-17 13:26:58 +00:00
Donny/강동윤
4b3dfdaa95
build: Update swc_core to v0.86.1 (#56770)
### What?

Update SWC crates, to apply bugfixes.

### Why?

We adjusted the mangling option to make it identical with `swcMinify:
false` with https://github.com/vercel/next.js/pull/56281, and it
revealed some bugs of the name mangler of the SWC minifier.

### How?


 - Fixes #56550
 - Fixes #56614

 - Turbopack counterpart: https://github.com/vercel/turbo/pull/6171

### Other Turbopack Changes

* https://github.com/vercel/turbo/pull/6177 <!-- Tim Neutkens - Add
support for FreeVarReference::Error -->
* https://github.com/vercel/turbo/pull/6180 <!-- Tobias Koppers - fix
chunk loading in build runtime -->
* https://github.com/vercel/turbo/pull/6191 <!-- Justin Ridgewell -
Deduplicate referenced_output_assets -->
* https://github.com/vercel/turbo/pull/6171 <!-- Donny/강동윤 - build:
Update `swc_core` to `v0.86.1` -->

Closes WEB-1775

---------

Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
2023-10-17 15:19:28 +02:00
Mateusz Burzyński
db214214d6
Update Babel dependencies (#51962)
### What?

Update Babel packages across the board

### Why?

Since you ship vendored presets and plugins it's impossible for people to update this stuff at their own pace - independently from Next. So users of `next/babel` are currently stuck with old versions and, for example, they might not be able to use the TS `satisfies` operator.

### How?

I just updated ranges (to pinned ones) where I could find them, run `corepack pnpm i` and re-run build scripts in the `packages/next`.

Fixes #43799
2023-10-17 02:25:57 +00:00
Juan Martín Seery
308a327923
feat(env): upgrade dotenv (#38481)
Upgraded dotenv to v16. Breaking changes are:

- Multiline parsing support
- Support inline comments
- Backtick support

[See their changelog](https://github.com/motdotla/dotenv/blob/master/CHANGELOG.md)

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [x] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`


Co-authored-by: Balázs Orbán <18369201+balazsorban44@users.noreply.github.com>
2023-10-17 00:57:51 +00:00
vercel-release-bot
24a146680f v13.5.6-canary.1 2023-10-16 23:24:30 +00:00
Josh Story
0a80017d03
Update React from d900fadbf to 09fbee89d. Removes server context and experimental prefix for server action APIs (#56809)
The latest React canary builds have a few changes that need to be
adopted for compatability.

1. the `useFormState` and `useFormStatus` hooks in `react-dom` and the
`formData` opiont in `react-dom/server` are no longer prefixed with
`experimental_`
2. server content (an undocumented React feature) has been removed. Next
only had trivial intenral use of this API and did not expose a coherent
feature to Next users (no ability to seed context on refetches). It is
still possible that some users used the React server context APIs which
is why this should go into Next 14.

### React upstream changes

- https://github.com/facebook/react/pull/27513
- https://github.com/facebook/react/pull/27514
- https://github.com/facebook/react/pull/27511
- https://github.com/facebook/react/pull/27508
- https://github.com/facebook/react/pull/27502
- https://github.com/facebook/react/pull/27474
- https://github.com/facebook/react/pull/26789
- https://github.com/facebook/react/pull/27500
- https://github.com/facebook/react/pull/27488
- https://github.com/facebook/react/pull/27458
- https://github.com/facebook/react/pull/27471
- https://github.com/facebook/react/pull/27470
- https://github.com/facebook/react/pull/27464
- https://github.com/facebook/react/pull/27456
- https://github.com/facebook/react/pull/27462
- https://github.com/facebook/react/pull/27461
- https://github.com/facebook/react/pull/27460
- https://github.com/facebook/react/pull/27459
- https://github.com/facebook/react/pull/27454
- https://github.com/facebook/react/pull/27457
- https://github.com/facebook/react/pull/27453
- https://github.com/facebook/react/pull/27401
- https://github.com/facebook/react/pull/27443
- https://github.com/facebook/react/pull/27445
- https://github.com/facebook/react/pull/27364
- https://github.com/facebook/react/pull/27440
- https://github.com/facebook/react/pull/27436

---------

Co-authored-by: Zack Tanner <zacktanner@gmail.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Co-authored-by: Jiachi Liu <inbox@huozhi.im>
2023-10-16 15:46:10 -07:00
vercel-release-bot
3c7d15b992 v13.5.6-canary.0 2023-10-16 22:04:56 +00:00
vercel-release-bot
54145b49f9 v13.5.5 2023-10-16 14:54:10 +00:00
vercel-release-bot
1609da2d95 v13.5.5-canary.19 2023-10-16 13:44:03 +00:00
vercel-release-bot
c1c419fde0 v13.5.5-canary.18 2023-10-16 12:28:32 +00:00
Kiko Beats
8f2fd2e7d5
bump: edge-runtime (#56856)
It bumps Edge Runtime to include the latest fixes, such as:

- https://github.com/vercel/edge-runtime/pull/622
- https://github.com/vercel/edge-runtime/pull/640

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2023-10-16 09:08:44 +02:00
vercel-release-bot
e5ad069c6a v13.5.5-canary.17 2023-10-15 23:22:55 +00:00
Balázs Orbán
b660eef8a2
chore: bump undici (#56851) 2023-10-14 23:45:02 +00:00
vercel-release-bot
297efa7bc9 v13.5.5-canary.16 2023-10-14 23:22:14 +00:00
vercel-release-bot
46d56c6bca v13.5.5-canary.15 2023-10-13 23:22:28 +00:00
vercel-release-bot
f3973d84a5 v13.5.5-canary.14 2023-10-13 22:44:36 +00:00
vercel-release-bot
f95a11f804 v13.5.5-canary.13 2023-10-13 16:34:44 +00:00
vercel-release-bot
489a528003 v13.5.5-canary.12 2023-10-13 13:23:54 +00:00
Tobias Koppers
a40a350155
Chunking Refactoring followup fixes (#56789)
### What?

fix some minor bugs
Make the page-loader reuse the client chunks

Closes WEB-1777
2023-10-13 12:38:59 +00:00
Tobias Koppers
04bad16bf4
Turbopack: Chunking Refactoring (#56756)
### What?

see https://github.com/vercel/turbo/pull/6160

### Turbopack Changes

* https://github.com/vercel/turbo/pull/6116 
* https://github.com/vercel/turbo/pull/6140 
* https://github.com/vercel/turbo/pull/6118 
* https://github.com/vercel/turbo/pull/6128 
* https://github.com/vercel/turbo/pull/6129 
* https://github.com/vercel/turbo/pull/6160 


Closes WEB-1772

Co-authored-by: Justin Ridgewell <112982+jridgewell@users.noreply.github.com>
2023-10-13 11:44:44 +00:00
vercel-release-bot
e0cd06531b v13.5.5-canary.11 2023-10-12 23:23:04 +00:00
vercel-release-bot
f306108b37 v13.5.5-canary.10 2023-10-12 23:09:37 +00:00