Closed eulersson closed 7 months ago
Will be fixed if all goes will with this issue resolution https://github.com/vercel/nft/issues/391 with PR https://github.com/vercel/nft/pull/392.
@vercel/nft
version 0.26.4
fixes it.
This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.
Link to the code that reproduces this issue
https://github.com/eulersson/zeromq.js-next.js-errors
To Reproduce
Manually
Basically create a next app
npx create-next-app@latest
with all the defaults, install zeromqnpm install zeromq@6.0.0-beta.19
, import it anywhere inapp/page.tsx
(e.g.import { Push } from "zeromq";
andconst sock = new Push();
anywhere in your file), start the development servernpm run dev
and visithttp://localhost:3000
.Reproducible Container
git@github.com:eulersson/zeromq.js-node.js-errors.git
docker build -t zeromq-nextjs
docker run --rm -it -p 3000:3000 nextjs-zeromq
http://localhost:3000
on your host browser.Current vs. Expected behavior
Observations
If I change this line in the
node-gyp-build/index.js
todir = '/absolute/path/to/node_modules/zeromq'
then it works! It seems that it needs to be in.next/server
... Because it looks for the prebuilds in there. I read and tried (unsuccessfully) the feature to includes files to the tracing process that happens where only the relevant files are moved to.next/server
so a standalone server can use that reduced selection of dependencies.Error Log
Full error log attached: full-error-log.txt
Error log except:
Provide environment information
Which area(s) are affected? (Select all that apply)
Not sure
Which stage(s) are affected? (Select all that apply)
next dev (local), next build (local), next start (local)
Additional context
I cannot have this simple hello world app running on macOS 14.1.1 either...
NEXT-2485