openclaw - ✅(Solved) Fix [Bug]: Select channel (QuickStart) [1 pull requests, 3 comments, 4 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#66677Fetched 2026-04-15 06:25:01
View on GitHub
Comments
3
Participants
4
Timeline
7
Reactions
2
Timeline (top)
commented ×3cross-referenced ×2labeled ×2

(OpenClaw 2026.4.14 (323493f))! Select channel (QuickStart) Skip for now TypeError: Cannot read properties of undefined (reading 'trim')

Root Cause

(OpenClaw 2026.4.14 (323493f))! Select channel (QuickStart) Skip for now TypeError: Cannot read properties of undefined (reading 'trim')

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

(OpenClaw 2026.4.14 (323493f))! Select channel (QuickStart) Skip for now TypeError: Cannot read properties of undefined (reading 'trim')

Steps to reproduce

(OpenClaw 2026.4.14 (323493f))! Select channel (QuickStart) Skip for now TypeError: Cannot read properties of undefined (reading 'trim')

Expected behavior

\

Actual behavior

\

OpenClaw version

2026.4.14

Operating system

macos 26 and Ubuntu

Install method

curl -fsSL https://openclaw.ai/install.sh | bash

Model

minimax

Provider / routing chain

?

Additional provider/model setup details

<img width="1267" height="1439" alt="Image" src="https://github.com/user-attachments/assets/f022be4e-5281-42b8-8e05-4969e65ab6c8" />

Logs, screenshots, and evidence

Impact and severity

No response

Additional information

No response

extent analysis

TL;DR

The error "TypeError: Cannot read properties of undefined (reading 'trim')" suggests that a variable or property is being accessed without being properly initialized or defined, and a fix would involve ensuring that the variable is correctly set before attempting to access its properties.

Guidance

  • Review the code changes between the previous working version and the current version (2026.4.14) to identify where the variable or property in question is being accessed without proper initialization.
  • Check for any recent updates or modifications to the QuickStart channel selection or the Skip for now functionality that might be related to the error.
  • Verify that all dependencies and libraries used by OpenClaw are up-to-date and compatible with the current version.
  • Inspect the install.sh script used for installation to ensure it does not introduce any issues that could lead to this error.

Example

No specific code example can be provided without more context, but the error typically occurs in a pattern like this:

let someVariable;
// someVariable is not assigned a value
console.log(someVariable.trim()); // This would throw "Cannot read properties of undefined (reading 'trim')"

To fix, ensure someVariable is assigned a value before trying to access its trim() method.

Notes

The provided information lacks specific details about the code changes or the exact line of code causing the error, making it challenging to provide a precise fix. The issue seems to be related to the QuickStart channel selection process in OpenClaw.

Recommendation

Apply a workaround by reviewing recent code changes and ensuring all variables are properly initialized before use, as the root cause seems to be related to an uninitialized variable rather than a version-specific issue.

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

\

Still need to ship something?

×6

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

Back to top recommendations

TRENDING