Commit graph

512 commits

Author SHA1 Message Date
Wyatt Johnson
eab1fe8397
Enable PPR for dynamic = "force-dynamic" (#58779)
This makes some critical modifications to the app render pipeline when
PPR has been enabled for pages with segments defining:

```js
export const dynamic = "force-dynamic"
```

Importantly, it no longer modifies the revalidation time to zero for
those pages, and now falls back to the provided default revalidation
time. When static render occurs, if the page being rendered has a
segment config defining `dynamic === "force-dynamic"`, then it will
postpone at the root of the component tree. This ensures that no render
code is executed for the page, as the entirety of the tree will have
postponed. This fixes the bug where the flight prefetch wasn't generated
correctly as well.
2023-12-06 01:10:00 +00:00
Leah
b88e263f4c
fix dev parallelism in daily turbopack tests (#59287)
Also fixes the retry running on forks (hopefully for real this time)

Closes PACK-2087
2023-12-05 15:41:49 +01:00
Leah
2cc88d7b11
fix missing checkout in daily turbopack reporting (#59256) 2023-12-04 18:54:00 +01:00
Leah
d348e4b569
fix missing echo in daily turbopack reporting (#59255)
### What?

GitHub workflow commands need to be echoed

Closes PACK-2075
2023-12-04 18:02:08 +01:00
Leah
b2e183ec1d
fix typo in daily turbopack integration test reporting (#59251) 2023-12-04 17:08:46 +01:00
Leah
15215d4c96
ci: report daily turbo integration test results from this repo (#58965)
### What?

A follow up for #58267 and #58394.

We no longer need the git branch for history it's stored in datadog now
and we also decided that we no longer need slack reporting.


Closes PACK-2039

---------

Co-authored-by: Tim Neutkens <tim@timneutkens.nl>
2023-12-04 16:18:42 +01:00
Zack Tanner
511867ceec
fix variable name in release workflow (#59135)
Follow up to https://github.com/vercel/next.js/pull/59134
2023-11-30 15:19:46 -08:00
Zack Tanner
f241f44b38
skip release if no new commits (#59134)
Prevents publishing canaries if there are no changes

Closes NEXT-1748
2023-11-30 15:07:05 -08:00
Leah
956636c86f
ci: don't retry or notify on failures from forks (#59118)
### Why?

For some reason the retry action can be triggered if there's a PR from
the canary branch of a fork.
https://github.com/vercel/next.js/actions/runs/7040561852/attempts/3



Closes PACK-2062
2023-11-30 13:03:44 +00:00
Leah
7ce4a02bdc
ci: don't try to upload to datadog for docs only changes (#59068) 2023-11-29 19:25:01 +01:00
JJ Kasper
5b94850d97
Update checkout step (#59079)
When jobs are cancelled we can end up with a bad `.git` tree so this
updates to have a fresh checkout step to avoid this

x-ref:
https://github.com/vercel/next.js/actions/runs/7036193103/job/19148358339?pr=59076
2023-11-29 10:07:22 -08:00
Balázs Orbán
d6d41dc66d
chore: bump nissuer (issue validator) (#59060)
### What?

Bumping the issue validator action [`nissuer`](https://github.com/balazsorban44/nissuer)

### Why?

It introduces two new features:

- Comments made by members of the Vercel organization are never hidden to avoid hiding useful information. Example: https://github.com/vercel/next.js/actions/runs/6780069984/job/18428144215
- A new option was added to do not allow `https://github.com/vercel/next.js.*` URLs as valid reproductions, as they are non-modified versions. We should require the reporter to go through the process of creating an isolated reproduction that we can clone and verify easily.

### How?

See https://github.com/balazsorban44/nissuer/releases/tag/1.8.0
2023-11-29 14:35:26 +00:00
Zack Tanner
809164d776
Enable PPR tests for test suites (#59030)
Cherry-picks #58708 without the dependency on https://github.com/vercel/next.js/pull/58779

Co-authored-by: Wyatt Johnson <633002+wyattjoh@users.noreply.github.com>
2023-11-29 03:22:45 +00:00
JJ Kasper
05f2c68b7a
Increase default timeout for swc build (#59035)
x-ref:
https://github.com/vercel/next.js/actions/runs/7022943529/attempts/3
2023-11-28 12:15:35 -08:00
Leah
f6babb4273
fix(CI): retry-test action can't use env in if (#58838) 2023-11-23 20:02:41 +01:00
Zack Tanner
0cb1c40400
ci: disable deployment protection for e2e test project (#58830)
Since we reset the test project on every e2e CI run, deployment protection is automatically enabled by default.

This adds an option to the reset project workflow to disable deployment protection. Our test runners need to be able to hit these pages from an unauthenticated browser in order for the tests to work. 

Verified tests are running properly in [this run](https://github.com/vercel/next.js/actions/runs/6971348806/job/18971225559) (fixing any failing tests themselves are out of scope for this PR; will evaluate once the run finishes)

Closes NEXT-1732
2023-11-23 09:41:34 -08:00
Zack Tanner
cbcd59889c
ci: unify reset project script (#58829)
We have identical `resetProject` code used in `bench/vercel` and our e2e workflow action -- this updates the `resetProject` script to side-effects free (hence removing the env var) and shared between bench & e2e

Closes NEXT-1731
2023-11-23 09:40:48 -08:00
Leah
d53ac4efee
chore(CI): add action to auto retry tests on canary and report failures after retries (#58774)
### What?

Due to flaky tests CI will sometimes fail on canary, we want to retry
before reporting them as broken on slack


Closes PACK-2022
2023-11-23 17:45:12 +01:00
Leah
8bdda745fb
chore(CI): improve datadog reporting (#58267) 2023-11-23 15:18:03 +01:00
Tobias Koppers
bcd0cb8948
fix branch name (#58132)
fix the branch name of the workflow
2023-11-14 11:23:02 +01:00
JJ Kasper
dc59d3cca9
Update CLI version for deploy examples job (#58318)
Fixes:
https://github.com/vercel/next.js/actions/runs/6830557044/job/18578715963
2023-11-13 11:36:51 -08:00
Justin Ridgewell
030021234b
Adjust update-turbopack-test-manifest.yml to run once per day (#58104)
The workflow is creating and closing PRs ever hour, which is too much.
2023-11-06 14:51:35 -05:00
Justin Ridgewell
26d9343419
Fix update-turbopack-test-manifest.yml workflow (#58097)
https://github.com/vercel/next.js/actions/runs/6774028544/job/18410200888#step:4:35
2023-11-06 12:31:11 -05:00
OJ Kwon
6f8c580386
feat(turbopack): Experimental wasm build (#57906)
### What?

continuation of https://github.com/vercel/next.js/pull/57851, since it is from a remote branch that I don't have access to write.

Co-authored-by: Maia Teegarden <2865858+padmaia@users.noreply.github.com>
Co-authored-by: Tim Neutkens <6324199+timneutkens@users.noreply.github.com>
2023-11-02 21:00:54 +00:00
Steven
be618048fe
chore(test): run unit tests on node 18 and 20 (#57199)
Since we separated unit tests into its own job in PR https://github.com/vercel/next.js/pull/55621, we can now run unit tests against Node.js 18 and Node.js 20 (maintenance and lts) using a matrix.
2023-11-02 10:43:18 +00:00
Zack Tanner
811e5c4fd5
move release undraft step until after canary is fully published (#57324)
Currently we publish a release in GitHub before it's actually fully published to npm. This moves the undraft step until after the publish is finished
2023-10-31 18:37:06 +00:00
Justin Ridgewell
79511317f6
Automatically update Turbopack test manifest (#57778)
### What?

This PR adds an hourly workflow that will update the test manifest used when testing with Turbopack.

### Why?

To ensure we don't regress any test suites.

### How?

I use the existing `scripts/update-fonts-data-workflow.js` workflow script which will execute a script, then create a PR with the current working tree. If any pending automated PRs exist, they will be closed when a new one is opened.
2023-10-31 02:06:48 +00:00
JJ Kasper
676d1ee4ce
Remove extra CI step and lock Node.js version (#57769)
Seems this command is causing intermittent issues and we don't actually need this information so removes it
2023-10-30 18:03:48 +00:00
Maia Teegarden
f412c8a991
Remove wasm target (#57437)
This PR removes the wasm target for the next-swc build for the next major version.  The main motivation is that Turbopack does not support targeting wasm yet, and it would be a significant amount of work to add. We plan to make Turbopack the default zero-config experience in a minor version, possibly before we are able to support a wasm target, so we need to make this breaking change now. We also plan to make more improvements to the webpack experience with shared Rust code, which we have so far been blocked from implementing because of the current wasm restrictions. We would like to support a wasm target again in the future, but cannot say at this time when that would be.


Closes WEB-1865
2023-10-26 02:29:07 +00:00
Tobias Koppers
462b8585b6
enable e2e tests with turbopack (#57432)
Closes WEB-1862

---------

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2023-10-25 19:46:31 +02:00
JJ Kasper
02fad82933
Revert "Increase build-native CI job timeout (#57314)" (#57325)
This reverts commit 003ec7a15b.

Re-adding this as a safe guard as the stalling was a real issue
2023-10-24 06:19:28 +00:00
Zack Tanner
56d74f42f4
bundle analyzer artifacts (#57307)
This uploads bundle analyzer artifacts during CI
2023-10-24 05:48:41 +00:00
JJ Kasper
003ec7a15b
Increase build-native CI job timeout (#57314)
This is currently timing out so this increases the timeout for Windows
specifically
2023-10-23 20:52:39 -07:00
JJ Kasper
639bc3af10
Increase concurrency for turbopack test run (#57290)
Aims to reduce run time by leveraging more concurrency

x-ref: https://github.com/vercel/next.js/actions/runs/6618039974/job/17975622987
2023-10-23 21:27:17 +00:00
JJ Kasper
191faf392c
Import turbo daily integration test workflows (#57083)
As discussed this imports our daily turbo integration tests workflow
into the Next.js repo
2023-10-23 11:48:38 -07:00
Ryo Matsukawa
9a8b14632c
chore: Add condition to skip update-fonts workflow on forks (#57165)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

### What?
Added a condition to skip the update-fonts workflow for forked
repositories.

### Why?
To optimize CI resources and prevent extra runs on forks.

### How?
By checking the repository name and comparing it with the main
repository before executing the workflow.
2023-10-21 00:50:36 -07:00
JJ Kasper
888c3a7439
Reduce e2e deploy concurrency (#57142)
Attempting to reduce our time outs for this job by reducing concurrency
2023-10-20 19:56:13 +00:00
JJ Kasper
a8bc1a1cf2
Update runner for e2e deploy tests (#57089)
This attempts to fix our tests timing out from an obscure lost
connection to runner message


![CleanShot 2023-10-19 at 16 29
50@2x](https://github.com/vercel/next.js/assets/22380829/594b21c4-4df9-418b-afbb-5e290020d25d)
2023-10-19 17:34:18 -07:00
Balázs Orbán
523474c8be
chore: lower Node.js version requirement (#56943) 2023-10-17 23:15:31 +02:00
Balázs Orbán
1ff7f07875
feat: drop Node.js 16 (#56896)
### What?

BREAKING CHANGE: Bump the minimum required Node.js version.

### Why?

Node.js 16 has reached end-of-life in September.

Bumped to `18.18.2` since it contained some security-related patches: https://nodejs.org/en/blog/vulnerability/october-2023-security-releases

### How?

Bumped `engines` where needed, upgraded the workflows.

This will allow us to remove quite a few polyfills, I'll open separate PRs for those.
2023-10-16 21:41:38 +00:00
JJ Kasper
329cd71f66
Skip artifact download for test e2e deploy workflow (#56807)
x-ref: https://github.com/vercel/next.js/actions/runs/6502354559
2023-10-13 20:00:34 +00:00
JJ Kasper
5004c8c50c
Trigger canary release nightly (#56758)
Follow-up to https://github.com/vercel/next.js/pull/56755 this updates to trigger at least one canary nightly before we run our E2E deploy tests.
2023-10-12 17:12:24 +00:00
JJ Kasper
0a6c60cec6
Break out E2E deploy test workflow to its own (#56755)
As discussed with @feedthejim this breaks our E2E deploy tests workflow into it's own so it can be triggered on cron/manually easier. 

One thing we'll need to consider with the cron/manual workflow is if a canary isn't published yet and Next.js relies on swc changes it will fail since this doesn't pack/publish a fresh built swc binary currently.
2023-10-12 16:34:27 +00:00
Jimmy Lai
ebebb6a96a
CI: add manual workflow for running e2e on prod (#56738)
This PR adds a job to the `build-and-deploy` workflow so that we run e2e
tests on production/vercel if the job was dispatched manually.

This is useful if you need to double-check your PR since we don't run
them on production for every PRs.

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->
2023-10-12 10:55:52 +02:00
Sukka
edb92a30b5
test: speed up isolated next instance test setup (#56525) 2023-10-07 00:15:59 +02:00
JJ Kasper
a970f28439
Add code freeze GitHub actions for releasing (#56325)
Co-authored-by: Steven <steven@ceriously.com>
Co-authored-by: Zack Tanner <zacktanner@gmail.com>
2023-10-02 23:10:40 +02:00
JJ Kasper
fb04b85bb6
Decrease default test timeouts (#56116)
When tests are timing out we shouldn't wait for 4 minutes before it officially fails so this brings down the default test timeouts
2023-09-27 23:55:20 +00:00
JJ Kasper
b596de89d3
Fix invalid build-and-test workflow (#56053)
x-ref: https://vercel.slack.com/archives/C04KC8A53T7/p1695763819725649
2023-09-26 14:45:49 -07:00
Tim Neutkens
a961ec0d5f
Skip production tests for Turbopack (#56045)
As Turbopack is only focusing on dev currently. 

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->
2023-09-26 22:30:04 +02:00
Tim Neutkens
73a6374de2
Move test/integration/production to test/production (#55981)
Moves `test/integration/production` to
`test/production/pages-dir/production` to leverage test isolation,
useful for when Turbopack runs for the test.

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->
2023-09-26 15:38:50 +02:00