fix(migrate): detect Yarn PnP config even when env overrides nodeLinker
@fengmk2 已经在做这个了。
开始于 2026年7月1日。
评估
这个 Issue 还没有评估数据。
描述
vp migrate currently treats YARN_NODE_LINKER=node-modules as enough to skip Yarn PnP handling. However, if the repository itself has .yarnrc.yml with nodeLinker: pnp, migration can complete successfully while leaving unsupported PnP config in the project. Future installs without that environment override will return to PnP mode.
Expected behavior:
- If
.yarnrc.ymlexplicitly setsnodeLinker: pnp, migration should not silently pass just becauseYARN_NODE_LINKER=node-modulesis set. - Preferably, migration should stop and ask the user to change the project config manually, or apply the existing node-modules conversion flow if that is the intended behavior.
YARN_NODE_LINKER=pnpshould still hard-block migration as today.
Suggested test:
Create a Yarn Berry fixture with:
# .yarnrc.yml
nodeLinker: pnp
Run migrate with:
YARN_NODE_LINKER=node-modules vp migrate --no-interactive
Assert that migration does not report the project as successfully migrated while leaving nodeLinker: pnp unchanged.
- 主要语言
- Rust
- 星标
- 5.8k
- 派生
- 263
- 平均合并
- 1 天 3 小时
- 30 天内合并 PR
- 147
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
voidzero-dev/vite-plus 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
voidzero-dev/vite-plus#2804 · 1 个 reaction ·
-
pending triage
难度 2/5 1-3 小时 新手友好度 75/100
voidzero-dev/vite-plus#2801 · 1 个 reaction ·
-
enhancement
难度 2/5 1-3 小时 新手友好度 62/100
voidzero-dev/vite-plus#2097 · 10 条评论 · 2 个 reaction ·
-
documentation
voidzero-dev/vite-plus#2800 · 已指派 1 人 ·
-
pending triage
难度 3/5 1-2 天 新手友好度 65/100
voidzero-dev/vite-plus#2796 · 1 条评论 ·
查看 voidzero-dev/vite-plus 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
-
state:needs triage
难度 2/5 1-3 小时 新手友好度 70/100
zed-industries/zed#64680 · 2 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 70/100
-
难度 2/5 1-3 小时 新手友好度 70/100
RustPython/RustPython#8802 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
TheLarkInn/aipm#2390 ·