openclaw - ✅(Solved) Fix [Bug]: TypeError: Cannot read properties of undefined (reading 'trim') during onboard / configure channel selection (v2026.4.14) [1 pull requests, 1 comments, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#66624Fetched 2026-04-15 06:25:17
View on GitHub
Comments
1
Participants
1
Timeline
4
Reactions
0
Participants
Timeline (top)
closed ×1commented ×1cross-referenced ×1labeled ×1

Fresh install of v2026.4.14 crashes with a TypeError at the end of the interactive setup wizard (channel selection step). The error also reproduces when running openclaw configure separately. The error does NOT occur on v2026.4.12.

Error Message

interactive setup wizard (channel selection step). The error also reproduces The error does NOT occur on v2026.4.12. Channel selection (or skip) should complete without error and finish setup.

Root Cause

Fresh install of v2026.4.14 crashes with a TypeError at the end of the interactive setup wizard (channel selection step). The error also reproduces when running openclaw configure separately. The error does NOT occur on v2026.4.12.

Fix Action

Fixed

PR fix notes

PR #66882: fix(wizard): guard text-input prompts against undefined clack results

Description (problem / solution / changelog)

Summary

Fixes the widespread onboarding crash:

TypeError: Cannot read properties of undefined (reading 'trim')

that kills openclaw onboard / openclaw configure during channel selection and channel-specific text-input steps (Telegram, Slack, Discord, etc.).

Root cause

@clack/prompts text() can resolve to undefined in some edge cases (e.g. submitting an empty value when neither initialValue nor placeholder is set), even though WizardPrompter.text is declared as Promise<string>. The wrapper in src/wizard/clack-prompter.ts passes the value through guardCancel but does not coerce the non-cancel path, so undefined leaks out to callers. buildChannelSetupWizardAdapterFromSetupWizard in src/channels/plugins/setup-wizard.ts then calls rawValue.trim() directly and crashes.

Fix

  • src/wizard/clack-prompter.ts — enforce the declared Promise<string> contract by coercing nullish results to "" after guardCancel. This covers every prompter.text caller in one place.
  • src/channels/plugins/setup-wizard.ts — belt-and-suspenders rawValue ?? "" at the existing call site so the same symptom can't be reintroduced by a future prompter swap.
  • src/wizard/clack-prompter.test.ts — unit tests for the wrapper covering both the undefined → "" coercion and the string passthrough.

Related issues

  • #66693 [Bug]: While onboarding: TypeError: Cannot read properties of undefined (reading 'trim')
  • #66718 [Bug] openclaw configure TypeError: Cannot read properties of undefined (reading 'trim')
  • #66848 [Bug]: TypeError: Cannot read properties of undefined (reading 'trim')
  • #66677 [Bug]: Select channel (QuickStart)
  • #66624 (closed) same symptom, v2026.4.14
  • #66728 (closed) Skip for now variant
  • #66641 (closed) installer crashes after Select channel (QuickStart)
  • #66619 (closed) Telegram setup variant

Test plan

  • New unit tests in src/wizard/clack-prompter.test.ts pass locally against the patched wrapper.
  • CI: pnpm test:unit / channel plugin tests.
  • Manual: openclaw onboard, pick Telegram, step through the text-input steps without hitting the TypeError.

Changed files

  • src/channels/plugins/setup-wizard-helpers.ts (modified, +7/-7)
  • src/channels/plugins/setup-wizard.ts (modified, +1/-1)
  • src/wizard/clack-prompter.test.ts (modified, +40/-2)
  • src/wizard/clack-prompter.ts (modified, +7/-1)
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

Version

OpenClaw 2026.4.14 (323493f) Node.js v22.22.2 Ubuntu Linux (VPS)

Description

Fresh install of v2026.4.14 crashes with a TypeError at the end of the interactive setup wizard (channel selection step). The error also reproduces when running openclaw configure separately. The error does NOT occur on v2026.4.12.

Steps to reproduce

Steps to Reproduce

  1. curl -fsSL https://openclaw.ai/install.sh | bash
  2. Installer completes and launches openclaw onboard
  3. Complete the wizard: accept security warning → QuickStart → skip model/auth
  4. At "Select channel (QuickStart)", select any option or "Skip for now"

Expected behavior

Proceed to next step.

Actual behavior

Crash: TypeError: Cannot read properties of undefined (reading 'trim')

Same crash with openclaw configure after a fresh install.

Expected Behavior

Channel selection (or skip) should complete without error and finish setup.

OpenClaw version

OpenClaw 2026.4.14 (323493f)

Operating system

Ubuntu 24.04

Install method

npm global

Model

gemini

Provider / routing chain

openclaw > api

Additional provider/model setup details

No response

Logs, screenshots, and evidence

Impact and severity

No response

Additional information

No response

extent analysis

TL;DR

Downgrade to OpenClaw version 2026.4.12 to avoid the TypeError crash during the interactive setup wizard.

Guidance

  • The error is likely caused by a regression introduced in version 2026.4.14, as the same steps work in version 2026.4.12.
  • To verify the issue, run openclaw configure separately after a fresh install of version 2026.4.14 and check for the TypeError.
  • Try downgrading to version 2026.4.12 using the install script with the specific version number, if available.
  • If downgrading is not feasible, consider waiting for a patch release or a fix in a future version of OpenClaw.

Notes

The provided information does not include specific details about the code changes or the exact cause of the TypeError. Therefore, the suggested solution is based on the observed behavior and the fact that the issue does not occur in version 2026.4.12.

Recommendation

Apply workaround: Downgrade to version 2026.4.12, as it is the last known working version, and wait for a future release that addresses the regression.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Proceed to next step.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING