#error onboarding

33 messages · Page 1 of 1 (latest)

prime zodiac
#

one error. "TypeError: Cannot read properties of undefined (reading 'trim')"

cannot progress at all. i needed to reset everything. how do i get past this?

jolly viperBOT
#

That specific ...reading 'trim' error during onboarding/setup is a known bug, not you doing something wrong.

Please check this first:

openclaw --version

If you're on 2026.4.14 or older, I'd try this:

openclaw update --tag main
openclaw doctor
openclaw gateway restart
openclaw onboard
prime zodiac
# jolly viper Why: there’s a fix on `main` for a setup crash that matches this exact error. D...

so fuck my chud life, i hate npm

npm error git dep preparation failed
npm error command /usr/bin/node /usr/lib/node_modules/npm/bin/npm-cli.js install --force --cache=/home/ubuntu/.npm --prefer-offline=false --prefer-online=false --offline=false --no-progress --no-save --no-audit --include=dev --include=peer --include=optional --no-package-lock-only --no-dry-run
npm error npm error code ENOTEMPTY
npm error npm error syscall rename
npm error npm error path /home/ubuntu/.npm-global/lib/node_modules/openclaw
npm error npm error dest /home/ubuntu/.npm-global/lib/node_modules/.openclaw-GwBTAFqU
npm error npm error errno -39
npm error npm error ENOTEMPTY: directory not empty, rename '/home/ubuntu/.npm-global/lib/node_modules/openclaw' -> '/home/ubuntu/.npm-global/lib/node_modules/.openclaw-GwBTAFqU'
npm error npm error A complete log of this run can be found in: /home/ubuntu/.npm/_logs/2026-04-15T16_29_17_007Z-debug-0.log
npm error A complete log of this run can be found in: /home/ubuntu/.npm/_logs/2026-04-15T16_28_24_021Z-debug-0.log
jolly viperBOT
#

Yeah, this one is npm being cursed, not your config.

You’ve moved past the original trim crash. Now the updater is failing with ENOTEMPTY because npm left a stale global openclaw dir behind.

I’d do option 2.

1) Quick fix, keep npm install
If npm root -g really is ~/.npm-global/lib/node_modules, clean the stale dirs and reinstall:

npm root -g
rm -rf ~/.npm-global/lib/node_modules/openclaw ~/.npm-global/lib/node_modules/.openclaw-*
curl -fsSL https://openclaw.ai/install.sh | bash -s -- --no-onboard
openclaw doctor
openclaw onboard
#

2) Better fix, stop fighting npm globals
Switch to the docs-recommended git install:

curl -fsSL https://openclaw.ai/install.sh | bash -s -- --install-method git --no-onboard
openclaw doctor
openclaw onboard

Why I’m recommending #2: the docs explicitly support the hackable git install, and it’s usually less miserable when you’re already in recovery mode.

Relevant docs:

If you want, paste:

#
  • openclaw --version
  • npm root -g

and I’ll tell you which of those two is safest on your box.

prime zodiac
jolly viperBOT
#

Oof, that’s awful. And no, 100 GB in 10 minutes is not normal.

A couple important things:

  • After npm → git switch, the old CLI process can still say weird “update again” stuff. The updater code explicitly skips some follow-up work after switching installs.
  • Also, by default update.checkOnStart only checks for updates. It does not auto-apply unless update.auto.enabled was turned on.

So first, let’s stop the bleeding and see where the bytes are going:

openclaw gateway stop
openclaw update status
du -xh --max-depth=2 ~/openclaw ~/.openclaw ~/.npm ~/.cache ~/.local/share/pnpm /tmp 2>/dev/null | sort -h | tail -40

If disk usage is still climbing after openclaw gateway stop, paste this too:

#
ps aux | grep -E 'openclaw|pnpm|npm|git' | grep -v grep

Then, if the git checkout is there, do the handoff cleanly from the repo install:

cd ~/openclaw
openclaw doctor
openclaw gateway restart

What I’d like to see:

  • output of openclaw update status
  • the last ~10 lines of that du output

Docs:

prime zodiac
#

yeah my disk is exploding when running the curl install

jolly viperBOT
#

Got it. Then stop using the curl installer on this box for now.

If the installer is what’s exploding disk, the clean fallback is the manual git install from the FAQ, which bypasses the installer path entirely.

First, stop the running install, then check what blew up:

du -sh /tmp/openclaw /tmp/openclaw-* ~/openclaw ~/.npm ~/.cache ~/.local/share/pnpm 2>/dev/null | sort -h

If the huge stuff is under /tmp/openclaw*, clear that temp junk after the installer is stopped.

Then do the manual git path:

git clone https://github.com/openclaw/openclaw.git ~/openclaw
#
cd ~/openclaw
pnpm install
pnpm build
openclaw doctor
openclaw gateway restart

That path is straight from the docs-supported npm → git switch flow:
https://docs.openclaw.ai/help/faq

If you paste the du output, I can tell you exactly which directory is going feral. If it’s /tmp/openclaw*, I’m pretty confident the installer temp path is the culprit, not your actual OpenClaw state.

prime zodiac
#

Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'openclaw' imported from /home/ubuntu/openclaw/dist/extensions/google/oauth.credentials.js
well. and that's currently the only oauth option i need right now, and id rather not add api keys rn

jolly viperBOT
#

Ah, okay, this helps.

That ERR_MODULE_NOT_FOUND smells like a bad npm → git handoff, not a Google OAuth problem itself.

Since you switched to a source checkout, don’t use the global openclaw binary for this step. Run it from the repo with pnpm:

cd ~/openclaw
node -v
pnpm install
pnpm build
pnpm openclaw configure

If you want the full wizard instead:

#
cd ~/openclaw
pnpm openclaw onboard

Why I’m pushing that: the docs explicitly say that if you don’t have a clean global install yet, use pnpm openclaw onboard from the checkout.

Also, please check this:

node -v

OpenClaw needs Node >= 22. If you’re on Ubuntu’s older stock Node, weird ESM/package-resolution garbage like this gets way more likely.

Docs:

thick glade
#

just do a downgrade to 2026.4.12 and then openclaw onboard... it works now...

jolly viperBOT
#

Nice catch, thanks, that really does sound like a regression.

For anyone blocked right now, pinning 2026.4.12 and rerunning openclaw onboard seems like the pragmatic workaround until the newer build is fixed.

If this fixed it, please right-click the solution message → Apps → ✅ Mark Solution so Answer Overflow can index it for the next person.

thick glade
jolly viperBOT
#

Yep, that’s the workaround message.

For convenience, the rollback paths are:

package install

pnpm add -g openclaw@2026.4.12
openclaw doctor
openclaw onboard

git/source checkout

cd ~/openclaw
git checkout 2026.4.12
pnpm install
#
pnpm build
openclaw doctor
openclaw onboard

If that gets you unstuck, please mark the solution so it lands in Answer Overflow.

prime zodiac
#

no thanks, would rather prefer a git checkout. would rather not stay on 2026.4.12 since like 12 security vulns get filed each day

jolly viperBOT
#

Fair, I’d want the git checkout too.

I’d do it this way, and avoid the global openclaw binary entirely until the handoff is clean:

node -v   # should be 22+
git clone https://github.com/openclaw/openclaw.git ~/openclaw
cd ~/openclaw
pnpm install
pnpm build
pnpm openclaw onboard

Key part: use pnpm openclaw onboard, not just openclaw onboard.

If latest main still dies specifically on Google OAuth with:

#
Cannot find package 'openclaw' imported from .../dist/extensions/google/oauth.credentials.js

then I think you’re hitting a current regression in that Google OAuth module on source installs.

Temporary git-checkout workaround on latest main:

In extensions/google/oauth.credentials.ts:

  1. delete this import:
import { lowercasePreservingWhitespace } from "openclaw/plugin-sdk/text-runtime";
  1. replace:
#
lowercasePreservingWhitespace(searchDir.replace(/\\/g, "/"))

with:

searchDir.replace(/\\/g, "/").toLowerCase()

Then rebuild:

cd ~/openclaw
pnpm build
pnpm openclaw onboard
#

If you want, paste node -v and whether pnpm openclaw onboard still throws that exact Google OAuth error, and I’ll narrow it down from there.

prime zodiac
#

yeah, still didnt work. well, fml, we're switching to 4.12

jolly viperBOT
#

Yeah, that’s totally fair.

At this point I’d call it a real regression on latest with Google OAuth/source install, not you messing it up.

So, pragmatic move:

pnpm add -g openclaw@2026.4.12
openclaw doctor
openclaw onboard

or for the git checkout:

cd ~/openclaw
#
git checkout 2026.4.12
pnpm install
pnpm build
openclaw doctor
openclaw onboard

Once you’re unstuck, if you have the patience, please file it here with the exact oauth.credentials.js error plus the “disk exploding on curl install” bit:
https://github.com/openclaw/openclaw/issues

And if 4.12 fixes it, please mark the solution so the next poor soul finds it on Answer Overflow.

prime zodiac
#

aaand it's not opening the browser to authenticate (and it doesn't give a url so fuck)

jolly viperBOT
#

Yeah, that’s a dumb one.

What’s probably happening is: it’s taking the local browser path, failing to actually open anything, and then not printing the fallback URL.

You can force the manual OAuth flow so it prints the URL:

unset DISPLAY WAYLAND_DISPLAY
pnpm openclaw onboard

or, if you’re not in the git checkout path:

unset DISPLAY WAYLAND_DISPLAY
openclaw onboard