platformioを久々に触ったらボタンからのアップロード等が効かない

環境

Windows 11 Home (25H2)

VSCode

バージョン: 1.121.0 (user setup)
コミット: f6cfa2ea2403534de03f069bdf160d06451ed282
日付: 2026-05-19T11:51:53+02:00
Electron: 39.8.8
ElectronBuildId: 13870025
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.26200

platformio

識別子
platformio.platformio-ide
バージョン
3.3.4
最終更新日時
1 時間前
サイズ
19.15MB

症状

ボタン操作で、platformio->upload等をしても以下のようにプロジェクトのフォルダ配下のexeを探しに行き実行できない。

 *  実行するタスク: c:\Users\ほげ\Documents\PlatformIO\Projects\cds\platformio.exe run --target upload 


* ターミナル プロセスが起動に失敗しました: シェル実行可能ファイル "c:\Users\ほげ\Documents\PlatformIO\Projects\cds\platformio.exe" へのパスが存在しません。

なお、[platformio:new terminal]のボタンは動作し、そこからコマンド入力ではパスも通って動作する。

PS C:\Users\ほげ\Documents\PlatformIO\Projects\cds> platformio.exe run –target upload

Processing nanoatmega328new (platform: atmelavr; board: nanoatmega328new; framework: arduino)

Verbose mode can be enabled via -v, --verbose option
CONFIGURATION: https://docs.platformio.org/page/boards/atmelavr/nanoatmega328new.html
PLATFORM: Atmel AVR (5.2.0) > Arduino Nano ATmega328 (New Bootloader)
HARDWARE: ATMEGA328P 16MHz, 2KB RAM, 30KB Flash
DEBUG: Current (avr-stub) External (avr-stub, simavr)
PACKAGES:

対処

Windowsの環境変数pathにplatformio.exeのあるフォルダ(C:\ほげ\kitam\.platformio\penv\Scripts)を追記しVSCode再起動

効果なかった対処

vscodeの設定から    “platformio-ide.customPATH”: を編集 -> 読まないっぽい

vscodeからplatformio拡張削除->効果なし

windows上でC:\ほげ\kitam\.platformioフォルダ事削除->効果なし

根本原因

不明。

C:\Users\ほげ.platformio\penv\Lib\site-packages\platformio\builder\tools\piointegration.py 追えばわかりそうな気はする。

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です