Failed to initialize virtual Python environment

Sysprogs forums Forums VisualGDB Failed to initialize virtual Python environment

This topic contains 1 reply, has 2 voices, and was last updated by  support 1 month, 2 weeks ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #33808



    I have a problem lastly, on my ESP32 projects: I received an error when I try to load them or create new projects. I use VGDB 5.6R9 build 4807, and I get this error, no matter what IDF I take:

    Run “C:\Users\Mattia Berton\AppData\Local\VisualGDB\Python3\python.exe c:\sysgcc\esp32\esp-idf\v5.0\tools\ install-python-env” in directory “” on local computer
    Creating a new Python environment in C:\Users\Mattia Berton\.espressif\python_env\idf5.0_py3.8_env
    Error: Command ‘[‘C:\\Users\\Mattia Berton\\.espressif\\python_env\\idf5.0_py3.8_env\\Scripts\\python.exe’, ‘-Im’, ‘ensurepip’, ‘–upgrade’, ‘–default-pip’]’ returned non-zero exit status 101.
    Traceback (most recent call last):
    File “c:\sysgcc\esp32\esp-idf\v5.0\tools\”, line 2610, in <module>
    File “c:\sysgcc\esp32\esp-idf\v5.0\tools\”, line 2602, in main
    File “c:\sysgcc\esp32\esp-idf\v5.0\tools\”, line 2022, in action_install_python_env
    subprocess.check_call([sys.executable, ‘-m’, ‘venv’,
    File “C:\Users\Mattia Berton\AppData\Local\VisualGDB\Python3\lib\”, line 364, in check_call
    raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command ‘[‘C:\\Users\\Mattia Berton\\AppData\\Local\\VisualGDB\\Python3\\python.exe’, ‘-m’, ‘venv’, ‘–clear’, ‘C:\\Users\\Mattia Berton\\.espressif\\python_env\\idf5.0_py3.8_env’]’ returned non-zero exit status 1.
    Command exited with code 1

    I already tried to follow the guide, but with no good result.

    Can you help me?

    Thank you,

    Mattia Berton




    According to this log, VisualGDB tries to run the setup script from ESP-IDF (C:\Users\Mattia Berton\AppData\Local\VisualGDB\Python3\python.exe c:\sysgcc\esp32\esp-idf\v5.0\tools\ install-python-env) and it fails with an error.

    Please try running the same script manually. If it fails with the same error, the issue is not on the VisualGDB side and is caused by something else in your system. You can try reaching out to Espressif to see if it’s a common issue with a known workaround. Once you get the script to work outside VisualGDB, it will work with VisualGDB as well.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.