`pnpm create vite-plus` and `yarn create vite-plus` fail with `spawn vp ENOENT` when `vp` is not on PATH
メンテナーはふだん 1 日以内に返信
評価
この issue はまだ評価されていません。
説明
Describe the bug
pnpm create vite-plus and yarn create vite-plus fail with spawn vp ENOENT at the dependency install step when no vp is on PATH. npm create vite-plus and bun create vite-plus succeed under the same conditions.
I expected create-vite-plus to work on a machine without a global Vite+ install, since it is the entry point recommended in #2970 and #3028.
The scaffold itself completes. Then vp create re-invokes vp install by bare command name (spawnargs: [ 'install' ]), and vp is not found. pnpm dlx and yarn dlx put only the bins of the requested package on PATH. After a pnpm create vite-plus run, the dlx directory's node_modules/.bin contains only create-vite-plus. vp belongs to the vite-plus dependency, so it is missing. npm's npx cache, by contrast, links vp and vpr next to create-vite-plus, which is why npm works. I did not inspect Yarn's dlx directory, but the symptom is the same.
A user with a global vp on PATH does not see this, because the bare vp then resolves to the global install. That install can also be a different version: here the global vp is 1.2.0 while create-vite-plus runs 1.3.0.
Reproduction
No repository needed; the steps below start from an empty directory.
Steps to reproduce
Use a shell whose PATH has Node.js and pnpm but no vp (I removed ~/.vite-plus/bin and kept the Node.js bin directory):
mkdir repro && cd repro
pnpm create [email protected] vite:application --directory app --no-agent --no-editor --no-git --no-hooks --no-interactive --verbose
# exit 1: spawn vp ENOENT
The same failure happens with --package-manager npm or --package-manager pnpm, and with Yarn 4.18.1:
corepack [email protected] create [email protected] vite:application --directory app --no-interactive --verbose
# exit 1: spawn vp ENOENT
For comparison, with the same PATH, these all exit 0 and install dependencies:
npm create [email protected] -- vite:application --directory app --no-interactive --verbose
bun create [email protected] vite:application --directory app --no-interactive --verbose
pnpm dlx --package [email protected] vp create vite:application --directory app --no-interactive --verbose
System Info
macOS (Darwin 27.0.0)
Node.js 24.22.0, pnpm 12.9.1 (Vite+ installed pnpm 12.14.0 for the template step), Yarn 4.18.1 through Corepack, npm 11.19.1, Bun 1.3.9
create-vite-plus 1.3.0, vite-plus 1.3.0
`vp --version` and `vp env current` are not applicable: the bug only reproduces without `vp` on PATH. The global vp on this machine, removed from PATH for the runs, reports v1.2.0.
Used Package Manager
pnpm (also Yarn)
Logs
Done in 97ms using pnpm v12.14.0
◆ ✔ Created vite.config.ts in app/vite.config.ts
◆ ✔ Merged staged config into app/vite.config.ts
▲ Failed to install git hooks
● Installing dependencies...
■ spawn vp ENOENT
Error: spawn vp ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:316:19)
at onErrorNT (node:internal/child_process:554:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
errno: -2,
code: 'ENOENT',
syscall: 'spawn vp',
path: 'vp',
spawnargs: [ 'install' ]
}
Failed to generate code: spawn vp ENOENT
(That log comes from a run with --git --hooks, which also shows Failed to install git hooks, probably for the same reason.)
Validations
- Read the Contributing Guidelines.
- Checked that there isn't already an issue for the same bug.
- Confirmed this is a Vite+ issue and not an upstream issue.
- The provided reproduction is a minimal reproducible example.
- 主要言語
- Rust
- スター
- 6.3k
- フォーク
- 283
- 平均マージ
- 1日 14時間
- マージ済み PR(30日)
- 231
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
voidzero-dev/vite-plus のほかの issue
-
pending triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
voidzero-dev/vite-plus#2882 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
voidzero-dev/vite-plus#2097 · コメント 10 件 · リアクション 2 件 ·
メンテナーはふだん 1 日以内に返信
-
vp migrate doesn't flag esbuild-specific config (minify: "esbuild") — migrated project fails to build on Vite 8対応中かも @john-okeefe が 1 日前に担当しました。 オープンcontribution welcome
voidzero-dev/vite-plus#3176 · リアクション 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
`vp run`: scripts get a non-blocking stdin (EAGAIN) when `run` tasks in vite.config.ts use constantsオープンpending triage
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
voidzero-dev/vite-plus#3155 ·
メンテナーはふだん 1 日以内に返信
-
Document cross-platform `FOO=bar cmd` in task commands and scripts対応中かも @hyunbinseo が 2 日前に担当しました。 オープンdocumentation
voidzero-dev/vite-plus#3140 · コメント 2 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
voidzero-dev/vite-plus の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
pedrovgs/UseCaseCoverage#23 ·
-
priority: low
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
storytold/photocraft#8687 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
area:kernel bug kernel-paused needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
bherbruck/solvecraft#5055 · コメント 2 件 ·
-
bug cli p3
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 3 日以内に返信
-
documentation good first issue help wanted
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信