Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Create with Storybook add-on hangs on pnpm 11 under “Running commands for Storybook…”

未关闭
#499 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
68/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
冷清
技术栈
node.js, storybook, typescript

调研方向

从 Storybook add-on 命令和包管理器翻译入手,然后跟踪 runCommandsAndInstallDependencies,查看子进程与 Clack spinner 是如何协调的。使用提供的 pnpm 11 命令在真实 TTY 中复现,并验证 Storybook 设置是否完成,或显示 approve-builds prompt,而不是看起来像是卡住了。

由索引模型根据 Issue 内容生成。

描述

Which project does this relate to?

Create Tanstack App

Describe the bug

If I run TanStack create with the Storybook add-on on pnpm 11, the CLI can appear to hang forever on:

Running commands for Storybook...

Example (same shape as other create reports; adjust version/flags as needed):

pnpm dlx @tanstack/cli@latest create tanstack-app \
  --framework react \
  --add-ons storybook \
  --no-git \
  -y

The create spinner never finishes that step. What’s actually happening is that TanStack runs the Storybook add-on command (npx storybook init -y --no-devpnpm dlx storybook … for pnpm users) with the spinner still active. On pnpm 11 (TTY + cold dlx cache), pnpm waits for interactive approve-builds input for esbuild, but that prompt is easy to miss under the spinner — so the TanStack CLI looks stuck.

This is a TanStack create UX/invocation issue: the parent owns the spinner and how the child is launched. Storybook’s JS has not started yet when the prompt appears, so Storybook cannot surface or answer it.

Related background (investigation from the Storybook side): https://github.com/storybookjs/storybook/issues/35668
Related (same pnpm 11 build-approval theme, different failure mode — hard ERR_PNPM_IGNORED_BUILDS instead of a hang): https://github.com/TanStack/cli/issues/484

Your Example Website or App

N/A as a hosted app — this is a local TanStack CLI create hang and needs a real TTY (StackBlitz / non-TTY environments won’t show the same interactive approve-builds path).

Repro is the TanStack create command above (or interactive pnpm dlx @tanstack/cli@latest create choosing React + Storybook on pnpm 11).

Steps to Reproduce the Bug or Issue
  1. Use pnpm 11+ in a real terminal (TTY).
  2. Optionally clear the pnpm dlx cache so the approve-builds path is more likely:
    rm -rf "$(dirname "$(pnpm store path)")/dlx"
  3. Run TanStack create with the Storybook add-on, e.g.:
pnpm dlx @tanstack/cli@latest create tanstack-app \
  --framework react \
  --add-ons storybook \
  --no-git \
  -y
  1. See the CLI sit on Running commands for Storybook... / appear hung.
  2. If you look carefully at the terminal (or pause the spinner), pnpm may be waiting on an approve-builds prompt for esbuild.
Expected behavior

As a user, I expected TanStack create to finish (or show a clear prompt I can answer). Instead it looks stuck on “Running commands for Storybook…” while the child is waiting on stdin.

Screenshots or Videos

No response

Platform
Additional context

Why this is on TanStack: create launches the Storybook add-on command and keeps the Clack spinner up for the whole child lifetime. Fixing visibility and/or passing pnpm allow-build flags is in that path (storybook add-on command + package-manager translation + runCommandsAndInstallDependencies).

Workaround for the underlying pnpm step (verified): if you run the child yourself,

pnpm --allow-build=esbuild dlx storybook@latest init -y --no-dev

Suggested fixes:

  1. When the package manager is pnpm, run the Storybook add-on command as pnpm --allow-build=esbuild dlx storybook init -y --no-dev (flag before dlx).
  2. Pause/stop the spinner when the child may need a TTY so pnpm’s approve-builds UI is visible.
  3. Document the workaround until (1) lands.
主要语言
TypeScript
星标
1.3k
派生
185
平均合并
18 小时 45 分钟
30 天内合并 PR
2

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

TanStack/cli 的其他 Issue

查看 TanStack/cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。