-
Notifications
You must be signed in to change notification settings - Fork 183
Closed
Description
Environment
With 3.16.0 I am getting the following error with a blank project created with bun create nuxt, as well as with all of my in-production projects:
[error] The requested module 'node:events' does not provide an export named 'addAbortListener'
import {addAbortListener} from 'node:events';
^^^^^^^^^^^^^^^^Reproduction
https://github.com/MickL/nuxt-cloudflare
(this is a blank project created with bun create nuxt)
Cloudflare logs with Bun:
2025-03-08T22:20:09.118331ZCloning repository...
2025-03-08T22:20:09.707574ZFrom https://github.com/MickL/nuxt-cloudflare
2025-03-08T22:20:09.708324Z * branch ce126b561539978d20fc2525535eac8a62c2aed2 -> FETCH_HEAD
2025-03-08T22:20:09.708475Z
2025-03-08T22:20:09.733332ZHEAD is now at ce126b5 packageManager was missing
2025-03-08T22:20:09.733846Z
2025-03-08T22:20:09.812942Z
2025-03-08T22:20:09.813448ZUsing v2 root directory strategy
2025-03-08T22:20:09.836259ZSuccess: Finished cloning repository files
2025-03-08T22:20:11.404792ZChecking for configuration in a Wrangler configuration file (BETA)
2025-03-08T22:20:11.405507Z
2025-03-08T22:20:12.503965ZNo wrangler.toml file found. Continuing.
2025-03-08T22:20:12.568802ZDetected the following tools from environment: [email protected], [email protected]
2025-03-08T22:20:12.569298ZInstalling bun 1.2.4
2025-03-08T22:20:12.695595ZDownloading Bun v1.2.4...
2025-03-08T22:20:13.85174ZArchive: /tmp/asdf-bun.v0iz/bun.zip
2025-03-08T22:20:14.612071Z inflating: /opt/buildhome/.asdf/downloads/bun/1.2.4/bun
2025-03-08T22:20:14.668693ZInstalling Bun v1.2.4...
2025-03-08T22:20:14.765439ZBun v1.2.4 is installed successfully!
2025-03-08T22:20:15.234695ZExecuting user command: bun install && bun run build
2025-03-08T22:20:15.455892Zbun install v1.2.4 (fd9a5ea6)
2025-03-08T22:20:16.741712Z
2025-03-08T22:20:16.741956Z$ nuxt prepare
2025-03-08T22:20:18.216647Z[error] The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:20:18.216944Z import {addAbortListener} from 'node:events';
2025-03-08T22:20:18.217083Z ^^^^^^^^^^^^^^^^
2025-03-08T22:20:18.21726Z SyntaxError: The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:20:18.217403Z at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
2025-03-08T22:20:18.217521Z at async ModuleJob.run (node:internal/modules/esm/module_job:190:5)
2025-03-08T22:20:18.21765Z
2025-03-08T22:20:18.217763Z[error] The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:20:18.226734Zerror: postinstall script from "nuxt-app" exited with 1
2025-03-08T22:20:18.234945ZFailed: Error while executing user command. Exited with error code: 1
2025-03-08T22:20:18.24625ZFailed: build command exited with code: 1
2025-03-08T22:20:18.984597ZFailed: error occurred while running build command
Cloudflare logs with NPM:
2025-03-08T22:17:51.345154Z Cloning repository...
2025-03-08T22:17:52.096348Z From https://github.com/MickL/nuxt-cloudflare
2025-03-08T22:17:52.096837Z * branch f5c9ff5c67a8245418955b507c5c7d58676995a9 -> FETCH_HEAD
2025-03-08T22:17:52.096948Z
2025-03-08T22:17:52.125865Z HEAD is now at f5c9ff5 first commit
2025-03-08T22:17:52.126717Z
2025-03-08T22:17:52.216649Z
2025-03-08T22:17:52.217664Z Using v2 root directory strategy
2025-03-08T22:17:52.242976Z Success: Finished cloning repository files
2025-03-08T22:17:53.859687Z Checking for configuration in a Wrangler configuration file (BETA)
2025-03-08T22:17:53.860761Z
2025-03-08T22:17:54.978701Z No wrangler.toml file found. Continuing.
2025-03-08T22:17:55.047327Z Detected the following tools from environment: [email protected], [email protected]
2025-03-08T22:17:55.047873Z Installing project dependencies: npm install --progress=false
2025-03-08T22:18:13.153504Z npm WARN EBADENGINE Unsupported engine {
2025-03-08T22:18:13.153802Z npm WARN EBADENGINE package: '[email protected]',
2025-03-08T22:18:13.154003Z npm WARN EBADENGINE required: { node: '^18.19.0 || >=20.5.0' },
2025-03-08T22:18:13.154172Z npm WARN EBADENGINE current: { node: 'v18.17.1', npm: '9.6.7' }
2025-03-08T22:18:13.154323Z npm WARN EBADENGINE }
2025-03-08T22:18:13.155363Z npm WARN EBADENGINE Unsupported engine {
2025-03-08T22:18:13.155596Z npm WARN EBADENGINE package: '[email protected]',
2025-03-08T22:18:13.155742Z npm WARN EBADENGINE required: { node: '>=18.18.0' },
2025-03-08T22:18:13.15586Z npm WARN EBADENGINE current: { node: 'v18.17.1', npm: '9.6.7' }
2025-03-08T22:18:13.155975Z npm WARN EBADENGINE }
2025-03-08T22:18:20.164527Z
2025-03-08T22:18:20.172148Z > postinstall
2025-03-08T22:18:20.172588Z > nuxt prepare
2025-03-08T22:18:20.178468Z
2025-03-08T22:18:21.79864Z [error] The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:18:21.798956Z import {addAbortListener} from 'node:events';
2025-03-08T22:18:21.799159Z ^^^^^^^^^^^^^^^^
2025-03-08T22:18:21.799272Z SyntaxError: The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:18:21.799406Z at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
2025-03-08T22:18:21.799574Z at async ModuleJob.run (node:internal/modules/esm/module_job:190:5)
2025-03-08T22:18:21.799691Z
2025-03-08T22:18:21.799802Z [error] The requested module 'node:events' does not provide an export named 'addAbortListener'
2025-03-08T22:18:21.822308Z npm ERR! code 1
2025-03-08T22:18:21.822784Z npm ERR! path /opt/buildhome/repo
2025-03-08T22:18:21.825756Z npm ERR! command failed
2025-03-08T22:18:21.826078Z npm ERR! command sh -c nuxt prepare
2025-03-08T22:18:21.828713Z
2025-03-08T22:18:21.828913Z npm ERR! A complete log of this run can be found in: /opt/buildhome/.npm/_logs/2025-03-08T22_17_55_783Z-debug-0.log
2025-03-08T22:18:21.865811Z Error: Exit with error code: 1
2025-03-08T22:18:21.866116Z at ChildProcess.<anonymous> (/snapshot/dist/run-build.js)
2025-03-08T22:18:21.866292Z at Object.onceWrapper (node:events:652:26)
2025-03-08T22:18:21.86644Z at ChildProcess.emit (node:events:537:28)
2025-03-08T22:18:21.866595Z at ChildProcess._handle.onexit (node:internal/child_process:291:12)
2025-03-08T22:18:21.884897Z Failed: build command exited with code: 1
2025-03-08T22:18:22.642777Z Failed: error occurred while running build command
FutureExcited, fanckush, joppehoekstra, Lonsho and ParsaJR
Metadata
Metadata
Assignees
Labels
No labels