Skip to content

meta: re-enable turbo prod/dev builds #7830

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

Merged
merged 3 commits into from
Jun 6, 2025
Merged

meta: re-enable turbo prod/dev builds #7830

merged 3 commits into from
Jun 6, 2025

Conversation

ovflowd
Copy link
Member

@ovflowd ovflowd commented Jun 2, 2025

This PR re-enables --turbo for ISR-based builds. It is experimental, but we're pilot testing this feature.

Signed-off-by: Claudio W. <cwunder@gnome.org>
@Copilot Copilot AI review requested due to automatic review settings June 2, 2025 18:10
@ovflowd ovflowd requested a review from a team as a code owner June 2, 2025 18:10
Copy link

vercel bot commented Jun 2, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nodejs-org ✅ Ready (Inspect) Visit Preview Jun 5, 2025 11:09am

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR re-enables the experimental --turbo flag for ISR-based production builds.

  • Updated the build script in package.json to include the --turbo flag.
  • Reverts the package.json build command to an experimental configuration for pilot testing.

@ovflowd
Copy link
Member Author

ovflowd commented Jun 2, 2025

cc @dario-piotrowicz I'm not sure how this affects our CF builds.

@ovflowd ovflowd added the github_actions:pull-request Trigger Pull Request Checks label Jun 2, 2025
@github-actions github-actions bot removed the github_actions:pull-request Trigger Pull Request Checks label Jun 2, 2025
Copy link

codecov bot commented Jun 2, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 75.47%. Comparing base (b486a5a) to head (57514f1).
Report is 21 commits behind head on main.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7830   +/-   ##
=======================================
  Coverage   75.47%   75.47%           
=======================================
  Files         101      101           
  Lines        8309     8309           
  Branches      218      218           
=======================================
  Hits         6271     6271           
  Misses       2036     2036           
  Partials        2        2           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

github-actions bot commented Jun 2, 2025

Lighthouse Results

URL Performance Accessibility Best Practices SEO Report
/en 🟢 99 🟢 100 🟢 100 🟢 91 🔗
/en/about 🟢 100 🟢 100 🟢 100 🟠 82 🔗
/en/about/previous-releases 🟢 99 🟢 100 🟢 100 🟠 83 🔗
/en/download 🟢 98 🟢 100 🟢 100 🟢 91 🔗
/en/blog 🟢 100 🟢 100 🟢 96 🟢 92 🔗

@ovflowd
Copy link
Member Author

ovflowd commented Jun 2, 2025

GitCommitInfo: timeout of 3000ms exceeded while running "git fetch origin b486a5a4b94b5e6f5c9790c0006b7baa9017d232"

is this normal on the Playwright CI? https://github.com/nodejs/nodejs.org/actions/runs/15399546042/job/43328619313?pr=7830

@avivkeller
Copy link
Member

avivkeller commented Jun 2, 2025


GitCommitInfo: timeout of 3000ms exceeded while running "git fetch origin b486a5a4b94b5e6f5c9790c0006b7baa9017d232"

is this normal on the Playwright CI? https://github.com/nodejs/nodejs.org/actions/runs/15399546042/job/43328619313?pr=7830

Yes, but https://github.com/nodejs/nodejs.org/actions/runs/15399546042/job/43328619313#step:22:1 is not

(If we increase the fetch depth we can make the git info wanting go away)

@ovflowd
Copy link
Member Author

ovflowd commented Jun 2, 2025


GitCommitInfo: timeout of 3000ms exceeded while running "git fetch origin b486a5a4b94b5e6f5c9790c0006b7baa9017d232"

is this normal on the Playwright CI? https://github.com/nodejs/nodejs.org/actions/runs/15399546042/job/43328619313?pr=7830

Yes, but https://github.com/nodejs/nodejs.org/actions/runs/15399546042/job/43328619313#step:11:1 is not

(If we increase the fetch depth we can make the git info wanting go away)

sadgers

Signed-off-by: Claudio W. <cwunder@gnome.org>
@ovflowd ovflowd changed the title meta: re-enable turbo prod builds meta: re-enable turbo prod/dev builds Jun 2, 2025
@dario-piotrowicz
Copy link
Member

cc @dario-piotrowicz I'm not sure how this affects our CF builds.

Thanks for the ping @ovflowd 🙂

From the looks of it the open-next adapter doesn't support that... 😓 we'll have to address this

If you do want to proceed with it right now, for the meantime if you want we can disable the open-next playwright tests

I'll look into prioritizing this as soon as we can 🙏

@avivkeller
Copy link
Member

Can we make a build:no-turbo temporarily? For OpenNext

@avivkeller avivkeller closed this Jun 2, 2025
@avivkeller avivkeller reopened this Jun 2, 2025
@avivkeller
Copy link
Member

Ack! Ignore that close, and the deleted comment above, I was on the wrong issue!

@dario-piotrowicz
Copy link
Member

Can we make a build:no-turbo temporarily? For OpenNext

good call, that's also a possibility yeah 🙂👍

(but that'd be a temporary solution at best I guess)

@ovflowd
Copy link
Member Author

ovflowd commented Jun 4, 2025

OOC, is the PR fine as it is or do we need to change anything?

@ovflowd
Copy link
Member Author

ovflowd commented Jun 4, 2025

From the looks of it the open-next adapter doesn't support that... 😓 we'll have to address this

Oh, it hooks into webpack?

@ovflowd
Copy link
Member Author

ovflowd commented Jun 4, 2025

Can we make a build:no-turbo temporarily? For OpenNext

good call, that's also a possibility yeah 🙂👍

(but that'd be a temporary solution at best I guess)

I think supporting both turbo (for CI and Vercel) and non-turbo for Cf and Playwright sounds good-ish to me :)

@avivkeller
Copy link
Member

avivkeller commented Jun 4, 2025

OOC, is the PR fine as it is or do we need to change anything?

Let's add a build:turboless script (name it whatever), and use it in OpenNext (@dario-piotrowicz I'm not sure where we define the build script for that)

@dario-piotrowicz
Copy link
Member

From the looks of it the open-next adapter doesn't support that... 😓 we'll have to address this

Oh, it hooks into webpack?

No, the fact is that the open-next adapter does some code manipulation on the output Next.js generates (using ast-grep). So the problem with turbo I believe is that the code generated by Next.js becomes different enough that some of the manipulations/patched that open-next does don't work anymore

@dario-piotrowicz
Copy link
Member

Let's add a build:turboless script (name it whatever), and use it in OpenNext (@dario-piotrowicz I'm not sure where we define the build script for that)

agreed 👍

Open-next allows you to define a build command to use: buildCommand

So, changing the open-next.config.ts file in the following way:
Screenshot 2025-06-05 at 10 29 24
should do the trick 🙂

@dario-piotrowicz
Copy link
Member

By the way, I've spoken with the Cloudflare open-next team and there is no current plan on starting to support the turbo build since it is an experimental feature and there are higher priority items the team is working/planning to work on.

However after discussing this with the team and checking the Next.js docs, my understanding is that building the app with or without turbopack does not have any impact on the final application that gets shipped (i.e. the production site doesn't get a performance boost or anything like that). So I hope that for the time being we're all happy with just building the Cloudflare version of the app without using turbopack 🙂

does anyone has any concern with this?

@ovflowd
Copy link
Member Author

ovflowd commented Jun 5, 2025

(i.e. the production site doesn't get a performance boost or anything like that). So I hope that for the time being we're all happy with just building the Cloudflare version of the app without using turbopack 🙂

I'm 100% fine with that and that's what I even suggested :)

@ovflowd ovflowd requested a review from a team as a code owner June 5, 2025 11:08
@ovflowd ovflowd added the github_actions:pull-request Trigger Pull Request Checks label Jun 5, 2025
@github-actions github-actions bot removed the github_actions:pull-request Trigger Pull Request Checks label Jun 5, 2025
@avivkeller
Copy link
Member

@dario-piotrowicz Can you review? Once you approve, i think this can land.

@dario-piotrowicz
Copy link
Member

@dario-piotrowicz Can you review? Once you approve, i think this can land.

Ah ok, thanks a lot for waiting for me 🫶

Copy link
Member

@dario-piotrowicz dario-piotrowicz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 😄

@ovflowd ovflowd added this pull request to the merge queue Jun 6, 2025
Merged via the queue into main with commit 0870b2b Jun 6, 2025
15 checks passed
@ovflowd ovflowd deleted the meta-reenable-turbo branch June 6, 2025 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants