Vite Plus PATH shim can shadow external CLI upgrades (OpenCode example)
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 50/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- node.js, rust
- 領域
- cli, operating-systems, tooling
調査の方向性
まず opencode --version と opencode upgrade --print-logs を使って Windows PowerShell のケースを再現し、次に Vite Plus が実行ファイルを ~/.vite-plus/bin に配置する方法と、PATH がそれらを解決する方法を調査します。外部アップグレードが成功した後、手動で置き換えなくても通常の opencode コマンドで新しくインストールされたバージョンが実行されれば完了です。ほかのケースが確認されない限り、OpenCode に関して示されている範囲を維持してください。
索引モデルが issue の本文から書いたものです。
説明
Summary
On Windows, a Vite Plus-owned executable in ~\.vite-plus\bin can remain ahead of a newer version installed by that CLI's own updater. The shell command then continues to run the stale Vite Plus executable.
OpenCode is the confirmed example below. This may affect any externally updatable CLI for which Vite Plus installs an executable with the same command name, but this report does not claim other packages are currently affected.
Environment
- Windows
- Vite Plus:
0.2.4 - OpenCode before upgrade:
1.17.18
Reproduction
opencode --version
# 1.17.18
opencode upgrade --print-logs
The updater reported:
Using method: npm
From 1.17.18 → 1.18.1
Upgrade complete
But immediately afterwards:
opencode --version
# 1.17.18
Investigation
The command resolved to the Vite Plus-owned path:
C:\Users\<user>\.vite-plus\bin\opencode.exe
The updater had installed OpenCode 1.18.1 at:
C:\Users\<user>\.vite-plus\js_runtime\node\22.19.0\node_modules\opencode-ai\bin\opencode.exe
Running that executable directly returned 1.18.1; the PATH executable remained at 1.17.18.
Scope checked
- Confirmed:
opencodewas shadowed by the stale Vite Plus executable. - Not implicated in this installation:
npm,npx, andcorepackresolve to NVM rather than~\.vite-plus\bin. - Potentially affected pattern: any CLI that manages its own upgrades while Vite Plus also places a same-named executable earlier on PATH.
Expected behavior
After a CLI reports a successful self-upgrade, its normal shell command should run the upgraded version.
Workaround
Replacing the stale Vite Plus executable with the newly installed OpenCode executable made opencode --version report 1.18.1.
Suggested direction
Vite Plus could avoid installing static, same-named binaries for externally self-updating CLIs, make them forwarding shims, or provide a way to refresh the Vite Plus bin entry after an external upgrade.
- 主要言語
- Rust
- スター
- 5.8k
- フォーク
- 263
- 平均マージ
- 1日 3時間
- マージ済み PR(30日)
- 147
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
voidzero-dev/vite-plus のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
voidzero-dev/vite-plus#2804 · リアクション 1 件 ·
-
pending triage
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
voidzero-dev/vite-plus#2801 · リアクション 1 件 ·
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
voidzero-dev/vite-plus#2097 · コメント 10 件 · リアクション 2 件 ·
-
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
-
bug github_actions
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
registrystack/registry-stack#1393 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
longbridge/gpui-kit#3223 ·
-
bug engine
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
rocky-data/rocky#2181 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
oasisprotocol/oasis-sdk#2523 ·
-
[indexer] [QA] Add a focused test for the new NonRetryableError / assertSocketAlive() behavior. オープンbot:ai-assisted component:indexer QA-roadmap status:untriaged
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
midnightntwrk/midnight-indexer#1557 ·