platformio / platformio-core-installer

PlatformIO Core Installer
https://docs.platformio.org/en/latest/core/installation/index.html
Apache License 2.0
85 stars 53 forks source link

Cannot install PIO core - python not found #3165

Closed dizcza closed 6 months ago

dizcza commented 6 months ago

I installed ESP-IDF plugin but cannot install PIO core. First, it said that I don't have python3.6+ installed although I do have (Ubuntu 22.04):

$ ll /usr/bin/python*
lrwxrwxrwx 1 root root   10 сер 18  2022 /usr/bin/python3 -> python3.10*
-rwxr-xr-x 1 root root 5,7M лис 20 17:14 /usr/bin/python3.10*

Neither clicking "I have python" nor disabling built-in Python helped. Then I spotted a related issue https://github.com/platformio/platformio-vscode-ide/issues/3949, removed suggested folders and now I cannot do anything - I'm getting another failure:

Error: Could not find compatible PlatformIO Core. Please enable `platformio-ide.useBuiltinPIOCore` setting and restart IDE.
    at MA.install (/home/dizcza/.vscode/extensions/platformio.platformio-ide-3.3.3-linux-x64/node_modules/platformio-node-helpers/dist/index.js:1:961468)
    at k.install (/home/dizcza/.vscode/extensions/platformio.platformio-ide-3.3.3-linux-x64/dist/extension.js:1:9318)
    at async /home/dizcza/.vscode/extensions/platformio.platformio-ide-3.3.3-linux-x64/dist/extension.js:1:45166...

Turning the abusing flag in the settings on and off does not do anything.

Trapped.

It should have been so easy...

dizcza commented 6 months ago

It seems I opened the issue not in the repository I started with. Should I transfer the text there - vscode?

dizcza commented 6 months ago

Suggestings in https://github.com/platformio/platformio-core-installer/issues/2284 didn't help as well.

dizcza commented 6 months ago
console.ts:137 [Extension Host] PlatformIO IDE Global State Object
console.ts:137 [Extension Host] runCommand /home/dizcza/miniconda3/bin/python3 Array(3) Object
console.ts:137 [Extension Host] /home/dizcza/miniconda3/bin/python3 Error: Error: The Python 3.9.12 (/home/dizcza/miniconda3/bin/python3) interpreter is not compatible.
Reason: Conda is not supported

    at /home/dizcza/.vscode/extensions/platformio.platformio-ide-3.3.3-linux-x64/node_modules/platformio-node-helpers/dist/index.js:1:5323
    at ChildProcess.i (/home/dizcza/.vscode/extensions/platformio.platformio-ide-3.3.3-linux-x64/node_modules/platformio-node-helpers/dist/index.js:1:4621)
    at ChildProcess.emit (node:events:514:28)
    at ChildProcess.emit (node:domain:489:12)
    at maybeClose (node:internal/child_process:1091:16)
    at Socket.<anonymous> (node:internal/child_process:449:11)
    at Socket.emit (node:events:514:28)
    at Socket.emit (node:domain:489:12)
    at Pipe.<anonymous> (node:net:323:12)
p @ console.ts:137
console.ts:137 [Extension Host] runCommand /home/dizcza/miniconda3/bin/python Array(3) Object
console.ts:137 [Extension Host] /home/dizcza/miniconda3/bin/python Error: Error: The Python 3.9.12 (/home/dizcza/miniconda3/bin/python) interpreter is not compatible.
Reason: Conda is not supported

...

Reason: Could not find Python `venv` module

You don't support conda? Such a pity. I didn't know. Well, at least logs are descriptive. So after I installed python3-pip and python3-venv packages, the platformio extension installation was finally completed.