-
-
Notifications
You must be signed in to change notification settings - Fork 110
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
Prerendering not working on Node 16 #896
Comments
Check if the build segfaults, this might be the same issue as #893 |
No segfault, but I'm on Windows.
|
Update: in addition to segfault fatal exit codes, I am also getting graceful exit codes but the pre-rendering pass just stops without handing over to my post-build process. Very strange bug, which occurs frequently locally on my dev computer (MacOS), as well as CloudFlare Pages builder, and GitHub Actions CI. Could this have anything to do with Preact WMR's NodeJS Worker used to invoke the prerender script? |
@danielweck yes, I think this is related to our use of What type of Nodejs installation are you using on MacOS? I notice this started when I updated to 16.13.1, but I'm not sure if the brew/nvm binaries have the same issue (perhaps they're linked against different versions of glibc?). |
Thanks Jason. |
Ah Ah, I am using this
Ugly, but "60% of the time, it works every time" 👍 |
I've reproduced build failures for a default project
macOS M1Running the build 100 times on the following versions fails n times:
Running build 10_000 times on the following versions fails n times:
I ran the build twice for 16.5.0. docker:16 images use debian buster and this glibc:
editI've also reproduced this on node:16-bullseye-slim
|
For what it's worth I can no longer reproduce the segfaults. Whatever bug in Node was causing them seems to be resolved? Personally on Node v16.16.0 |
Can confirm on Node v16.17.0 on Windows 10 x64: > npm run build
> build
> wmr build --prerender
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db
Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db
Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating
Wrote 27Kb to disk:
dist\index.html 460b
dist\index.883c8e44.js 18Kb
dist\assets/style.e6ee4bcf.css 499b
dist\chunks/prerender.ef8ef4be.js 7.7Kb
dist\chunks/index.7fb9d5bb.js 214b
Prerendered 3 pages:
/
/about [from /]
/error [from /] |
I've ran the CI a few times in the past few days too, haven't ran into it. I'm going to tentatively say this is resolved and close it out. If anyone runs into issues feel free to reply and we can reopen. |
Hello, running into the same problem maybe On a fresh new project on a windows machine.
|
@PodaruDragos Indeed, unfortunately we've noticed this too. |
Describe the bug
When running prerender on Node 16, the pages don't get prerendered.
To Reproduce
Steps to reproduce the behavior:
npm init wmr example && cd example
npm run build
(which in turn runswmr build --prerender
)Expected behavior
The page should get prerendered and the resulting HTML should contain everything. This is the build output:
This is the resulting
dist/index.html
:Now the same on Node 14:
You can see that it prerenders. The resulting
index.html
is correct:Bug occurs with:
wmr
orwmr start
(development)wmr build
(production)wmr serve
Desktop (please complete the following information):
Additional context
N/A
The text was updated successfully, but these errors were encountered: