-
Notifications
You must be signed in to change notification settings - Fork 208
Open
Description
Hi!
While building a Next.js project that includes RDFLib ([email protected]), the build fails due to a missing module error in rdf-canonize:
Module not found: Can't resolve 'rdf-canonize-native' in '.../node_modules/.pnpm/[email protected]/node_modules/rdf-canonize/lib'This error seems to originate from rdf-canonize, which is a dependency of jsonld, which in turn is required by RDFLib.
Steps to Reproduce
- Create a Next.js project ([email protected]).
- Install [email protected] using pnpm.
- Run next build.
Expected Behavior
The build should complete successfully without missing dependencies.
Actual Behavior
- The build fails with Module not found: Can't resolve 'rdf-canonize-native'.
- The issue appears in the dependency chain: rdflib → jsonld → rdf-canonize.
- A separate TypeError: Cannot set properties of undefined (setting 'WordArray') also appears in the logs.
Environment
- Package Manager: pnpm
- RDFLib Version: 2.2.37
- Next.js Version: 15.2.1
- Node.js Version: 23.9.0
Attempts to solve
- Add rdf-canonize-native dependency → Failed (different error) at installation
Full Log
next dev
▲ Next.js 15.2.1
- Local: http://localhost:3000
- Network: http://192.168.68.105:3000
✓ Starting...
✓ Ready in 2.7s
○ Compiling / ...
⚠ ./node_modules/.pnpm/[email protected]/node_modules/rdf-canonize/lib/index.js
Module not found: Can't resolve 'rdf-canonize-native' in '.../node_modules/.pnpm/[email protected]/node_modules/rdf-canonize/lib'
Import trace for requested module:
./node_modules/.pnpm/[email protected]/node_modules/rdf-canonize/lib/index.js
./node_modules/.pnpm/[email protected]/node_modules/rdf-canonize/index.js
./node_modules/.pnpm/[email protected][email protected]/node_modules/jsonld/lib/jsonld.js
./node_modules/.pnpm/[email protected][email protected]/node_modules/jsonld/lib/index.js
./node_modules/.pnpm/[email protected][email protected]/node_modules/rdflib/esm/jsonldparser.js
./node_modules/.pnpm/[email protected][email protected]/node_modules/rdflib/esm/fetcher.js
./node_modules/.pnpm/[email protected][email protected]/node_modules/rdflib/esm/index.jsConclusion
Thank you in advance!!!
Metadata
Metadata
Assignees
Labels
No labels