Missing undici dependency causes ERR_MODULE_NOT_FOUND #7

Closed
opened 2026-02-15 17:15:02 -05:00 by yindo · 0 comments
Owner

Originally created by @josh-sophon on GitHub (Jan 23, 2026).

Description

Running bunx clawdhub@latest or npx clawdhub@latest fails with:

Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'undici' imported from .../node_modules/clawdhub/dist/http.js

Environment

  • Node.js v23.10.0
  • clawdhub v0.3.0
  • macOS

Root Cause

dist/http.js imports undici, but undici is not listed in package.json dependencies.

Suggested Fix

Add undici to the dependencies in package.json:

"dependencies": {
  "undici": "^6.0.0",
  ...
}

Workaround

Installing locally with undici works:

mkdir fix && cd fix && npm init -y && npm install clawdhub undici
./node_modules/.bin/clawdhub --help
Originally created by @josh-sophon on GitHub (Jan 23, 2026). ## Description Running `bunx clawdhub@latest` or `npx clawdhub@latest` fails with: ``` Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'undici' imported from .../node_modules/clawdhub/dist/http.js ``` ## Environment - Node.js v23.10.0 - clawdhub v0.3.0 - macOS ## Root Cause `dist/http.js` imports `undici`, but `undici` is not listed in `package.json` dependencies. ## Suggested Fix Add `undici` to the `dependencies` in `package.json`: ```json "dependencies": { "undici": "^6.0.0", ... } ``` ## Workaround Installing locally with undici works: ```bash mkdir fix && cd fix && npm init -y && npm install clawdhub undici ./node_modules/.bin/clawdhub --help ```
yindo closed this issue 2026-02-15 17:15:02 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: openclaw/clawhub#7