-
Notifications
You must be signed in to change notification settings - Fork 304
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug Report]: Error "Please use idf.py only in an ESP-IDF shell environment." when running idf.py from a special terminal (VSC-943) #769
Comments
I can run the following command manually inside the special terminal and things start to work..
Although this is a manual process and probably should not need to be done. |
Hi @iangregsondev I've noticed that some tools were not being installed (those tar.xz) and the linked PR should fix the issue. Could you try this vsix installer and see if it works for you ? |
@brianignacio5 The problem ( |
@brianignacio5 Created new issue #959 |
Describe the bug
Opening the IDF Terminal using the following icon
Gives an error when trying to run idf.py
To Reproduce
Just open the terminal (terminal idf) from the lower toolbar button and type idf.py.
Expected behavior
Should recongnise its in the special terminal and not give an error message
Screenshots
See above
Environment (please complete the following information):
Output
---------------------------------------------- ESP-IDF Extension for Visual Studio Code report ---------------------------------------------
OS darwin arm64 21.5.0
System environment variable IDF_PYTHON_ENV_PATH
undefined
System environment variable PATH
/Users/ian/.sdkman/candidates/micronaut/current/bin:/Users/ian/.sdkman/candidates/java/current/bin:/Users/ian/.sdkman/candidates/gradle/current/bin:/Users/ian/.pyenv/shims:/Users/ian/.nvm/versions/node/v16.15.1/bin:/Users/ian/.gvm/pkgsets/go1.18.1/global/bin:/Users/ian/.gvm/gos/go1.18.1/bin:/Users/ian/.gvm/pkgsets/go1.18.1/global/overlay/bin:/Users/ian/.gvm/bin:/Users/ian/.gvm/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/MacGPG2/bin:/usr/local/share/dotnet:~/.dotnet/tools:/Library/Apple/usr/bin:/Users/ian/.cargo/bin:/Users/ian/.local/bin:/Users/ian/.local/bin:/Users/ian/jetbrains-shell-scripts:/Users/ian/flutter/bin
System environment variable PYTHON
undefined
Visual Studio Code version 1.69.2
Visual Studio Code language en
Visual Studio Code shell /bin/zsh
ESP-IDF Extension version 1.4.0
---------------------------------------------------- Extension configuration settings ------------------------------------------------------
ESP-ADF Path (idf.espAdfPath) ${env:ADF_PATH}
ESP-IDF Path (idf.espIdfPath) /Users/ian/esp/esp-idf
ESP-MDF Path (idf.espMdfPath) ${env:MDF_PATH}
Custom extra paths (idf.customExtraPaths) /Users/ian/.espressif/tools/xtensa-esp-elf-gdb/11.2_20220715/xtensa-esp-elf-gdb/bin:/Users/ian/.espressif/tools/riscv32-esp-elf-gdb/11.2_20220715/riscv32-esp-elf-gdb/bin:/Users/ian/.espressif/tools/xtensa-esp32-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32-elf/bin:/Users/ian/.espressif/tools/xtensa-esp32s2-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32s2-elf/bin:/Users/ian/.espressif/tools/xtensa-esp32s3-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32s3-elf/bin:/Users/ian/.espressif/tools/riscv32-esp-elf/esp-2022r1-RC1-11.2.0/riscv32-esp-elf/bin:/Users/ian/.espressif/tools/esp32ulp-elf/2.28.51-esp-20191205/esp32ulp-elf-binutils/bin:/Users/ian/.espressif/tools/esp32s2ulp-elf/2.28.51-esp-20191205/esp32s2ulp-elf-binutils/bin:/Users/ian/.espressif/tools/openocd-esp32/v0.11.0-esp32-20220706/openocd-esp32/bin
Custom extra vars (idf.customExtraVars) {"OPENOCD_SCRIPTS":"/Users/ian/.espressif/tools/openocd-esp32/v0.11.0-esp32-20220706/openocd-esp32/share/openocd/scripts"}
Virtual env Python Path (idf.pythonBinPath) /Users/ian/.espressif/python_env/idf5.0_py3.10_env/bin/python
Serial port (idf.port) /dev/cu.usbmodem1113201
OpenOCD Configs (idf.openOcdConfigs) board/esp32s3-bridge.cfg
ESP-IDF Tools Path (idf.toolsPath) /Users/ian/.espressif
Git Path (idf.gitPath) /opt/homebrew/bin/git
-------------------------------------------------------- Configurations access -------------------------------------------------------------
Access to ESP-ADF Path (idf.espAdfPath) false
Access to ESP-IDF Path (idf.espIdfPath) true
Access to ESP-MDF Path (idf.espMdfPath) false
Access to ESP-IDF Custom extra paths
Access to /Users/ian/.espressif/tools/xtensa-esp-elf-gdb/11.2_20220715/xtensa-esp-elf-gdb/bin: true
Access to /Users/ian/.espressif/tools/riscv32-esp-elf-gdb/11.2_20220715/riscv32-esp-elf-gdb/bin: true
Access to /Users/ian/.espressif/tools/xtensa-esp32-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32-elf/bin: true
Access to /Users/ian/.espressif/tools/xtensa-esp32s2-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32s2-elf/bin: true
Access to /Users/ian/.espressif/tools/xtensa-esp32s3-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32s3-elf/bin: true
Access to /Users/ian/.espressif/tools/riscv32-esp-elf/esp-2022r1-RC1-11.2.0/riscv32-esp-elf/bin: true
Access to /Users/ian/.espressif/tools/esp32ulp-elf/2.28.51-esp-20191205/esp32ulp-elf-binutils/bin: true
Access to /Users/ian/.espressif/tools/esp32s2ulp-elf/2.28.51-esp-20191205/esp32s2ulp-elf-binutils/bin: true
Access to /Users/ian/.espressif/tools/openocd-esp32/v0.11.0-esp32-20220706/openocd-esp32/bin: true
Access to Virtual env Python Path (idf.pythonBinPath) true
Access to CMake in environment PATH true
Access to Ninja in environment PATH true
Access to ESP-IDF Tools Path (idf.toolsPath) true
----------------------------------------------------------- Executables Versions -----------------------------------------------------------
Git version 2.37.1
ESP-IDF version 5.0
Python version 3.10.5
Python's pip version 22.2.1
-------------------------------------------------- Python packages in idf.pythonBinPath ----------------------------------------------------
bitstring version: 3.1.9
certifi version: 2022.6.15
cffi version: 1.15.1
charset-normalizer version: 2.1.0
click version: 8.0.4
colorama version: 0.4.5
construct version: 2.10.68
contextlib2 version: 21.6.0
cryptography version: 36.0.2
ecdsa version: 0.18.0
esp-coredump version: 1.2
esptool version: 4.1
freertos-gdb version: 1.0.1
future version: 0.18.2
gcovr version: 5.1
idf-component-manager version: 1.1.4
idna version: 3.3
Jinja2 version: 3.1.2
kconfiglib version: 14.1.0
lxml version: 4.9.1
MarkupSafe version: 2.1.1
pip version: 22.2.1
psutil version: 5.9.1
pycparser version: 2.21
pyelftools version: 0.27
pygdbmi version: 0.9.0.2
Pygments version: 2.12.0
pyparsing version: 3.0.9
pyserial version: 3.5
PyYAML version: 6.0
reedsolo version: 1.5.4
requests version: 2.28.1
requests-toolbelt version: 0.9.1
schema version: 0.7.5
setuptools version: 63.2.0
six version: 1.16.0
tqdm version: 4.64.0
urllib3 version: 1.26.11
websocket-client version: 1.3.3
wheel version: 0.37.1
xmlrunner version: 1.7.7
---------------------------------------------------- Check ESP-IDF python requirements.txt -------------------------------------------------
Check ESP-IDF Python packages Error
---------------------------------------------------- Check extension requirements.txt ------------------------------------------------------
Check Extension Python packages Python requirements are satisfied.
---------------------------------------------------- Check ESP-IDF debug adapter requirements.txt ------------------------------------------
Check Debug AdapterPython packages Python requirements are satisfied.
---------------------------------------------------- Visual Studio Code launch.json --------------------------------------------------------
{
"version": "0.2.0",
"configurations": [
{
"type": "espidf",
"name": "Launch",
"request": "launch"
}
]
}
---------------------------------------------------- Visual Studio Code c_cpp_properties.json ----------------------------------------------
{
"configurations": [
{
"name": "ESP-IDF",
"compilerPath": "/Users/ian/.espressif/tools/xtensa-esp32-elf/esp-2022r1-RC1-11.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc",
"cStandard": "c11",
"cppStandard": "c++17",
"includePath": [
"${config:idf.espIdfPath}/components/",
"${config:idf.espIdfPathWin}/components/",
"${config:idf.espAdfPath}/components/",
"${config:idf.espAdfPathWin}/components/",
"${workspaceFolder}/"
],
"browse": {
"path": [
"${config:idf.espIdfPath}/components",
"${config:idf.espIdfPathWin}/components",
"${config:idf.espAdfPath}/components/",
"${config:idf.espAdfPathWin}/components/**",
"${workspaceFolder}"
],
"limitSymbolsToIncludedHeaders": false
}
}
],
"version": 4
}
----------------------------------------------------------- Latest error -----------------------------------------------------------------
Latest error at Command failed: /Users/ian/.espressif/python_env/idf5.0_py3.10_env/bin/python /Users/ian/esp/esp-idf/tools/check_python_dependencies.py -r "/Users/ian/esp/esp-idf/requirements.txt"
Traceback (most recent call last):
File "/Users/ian/esp/esp-idf/tools/check_python_dependencies.py", line 40, in
with open(req_path) as f:
FileNotFoundError: [Errno 2] No such file or directory: '/Users/ian/esp/esp-idf/requirements.txt'
In Visual Studio Code select menu
View
->Output
-> ESP-IDF, ESP-IDF Debug Adapter, Heap Trace, OpenOCD and SDK Configuration Editor.Please share the output of the channel related to your issue. For example ESP-IDF is used mostly for the extension setup process output.
Logs
Please share the log file which can be obtained from:
%USERPROFILE%\.vscode\extensions\espressif.esp-idf-extension-VERSION\esp_idf_vsc_ext.log
$HOME/.vscode/extensions/espressif.esp-idf-extension-VERSION/esp_idf_vsc_ext.log
Extension Configuration settings
Open Command Palette (F1 or View Menu -> Command Palette) and type
Preferences: Open Settings (JSON)
or use{CURRENT_PROJECT}/.vscode/settings.json
to get the following extension configuration settings value:idf.espIdfPath
(MacOS or Linux) oridf.espIdfPathWin
(Windows) also calledPath to locate ESP-IDF framework (IDF_PATH)
inPreferences: Open Settings (UI)
.idf.pythonBinPath
(MacOS or Linux) oridf.pythonBinPathWin
(Windows) also calledPython absolute binary path used to execute ESP-IDF Python Scripts
inPreferences: Open Settings (UI)
.idf.openOcdConfigs
also calledList of configuration files inside OpenOCD Scripts directory
inPreferences: Open Settings (UI)
.idf.customExtraPaths
also calledPaths to be appended to PATH
inPreferences: Open Settings (UI)
.idf.customExtraVars
also calledVariables to be added to system environment variables
inPreferences: Open Settings (UI)
.idf.adapterTargetName
also calledTarget name for ESP-IDF Debug Adapter
inPreferences: Open Settings (UI)
.idf.customAdapterTargetName
is used whenidf.adapterTargetName
is set tocustom
.Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: