Failed to initialize virtual Python environment

Sysprogs forums Forums VisualGDB Failed to initialize virtual Python environment

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

    Hello,

    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\idf_tools.py 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\idf_tools.py”, line 2610, in <module>
    main(sys.argv[1:])
    File “c:\sysgcc\esp32\esp-idf\v5.0\tools\idf_tools.py”, line 2602, in main
    action_func(args)
    File “c:\sysgcc\esp32\esp-idf\v5.0\tools\idf_tools.py”, line 2022, in action_install_python_env
    subprocess.check_call([sys.executable, ‘-m’, ‘venv’,
    File “C:\Users\Mattia Berton\AppData\Local\VisualGDB\Python3\lib\subprocess.py”, 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 https://visualgdb.com/documentation/espidf/#python, but with no good result.

    Can you help me?

    Thank you,

    Mattia Berton

    #33809
    support
    Keymaster

    Hi,

    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\idf_tools.py 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.