So I just uninstalled and reinstalled VScode, uninstalled Platformio, deleted all existing projects and the .platformio directory in users/xxxx/. Next I restarted and reinstalled Platformio.
Now when I try and create a new project (espidf) it fails with the following log.
PIO Core Call Error: "The current working directory D:\Documents\PlatformIO\Projects\EspIdfTestProject will be used for the project.
The next files/directories have been created in D:\Documents\PlatformIO\Projects\EspIdfTestProject
include - Put project header files here
lib - Put here project specific (private) libraries
src - Put project source files here
platformio.ini - Project Configuration File
Resolving lolin_d32_pro dependencies...
Already up-to-date.
Updating metadata for the vscode IDE...
Error: Processing lolin_d32_pro (platform: espressif32; board: lolin_d32_pro; framework: espidf)
--------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/lolin_d32_pro.html
PLATFORM: Espressif 32 (5.3.0) > WEMOS LOLIN D32 PRO
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-espidf @ 3.40403.0 (4.4.3)
- tool-cmake @ 3.16.4
- tool-esptoolpy @ 1.40400.0 (4.4.0)
- tool-idf @ 1.0.1
- tool-mconf @ 1.4060000.20190628 (406.0.0)
- tool-ninja @ 1.9.0
- toolchain-esp32ulp @ 1.23500.220830 (2.35.0)
- toolchain-xtensa-esp32 @ 8.4.0+2021r2-patch5
Installing ESP-IDF's Python dependencies
Collecting cryptography<35.0.0,>=2.1.4
Using cached cryptography-3.4.8-cp36-abi3-win_amd64.whl (1.6 MB)
Collecting future>=0.15.2
Using cached future-0.18.3-py3-none-any.whl
Collecting kconfiglib==13.7.1
Using cached kconfiglib-13.7.1-py2.py3-none-any.whl (145 kB)
Collecting idf-component-manager~=1.0
Using cached idf_component_manager-1.2.1-py3-none-any.whl (116 kB)
Collecting cffi>=1.12
Using cached cffi-1.15.1-cp39-cp39-win_amd64.whl (179 kB)
Collecting pyyaml>5.2
Using cached PyYAML-6.0-cp39-cp39-win_amd64.whl (151 kB)
Collecting cachecontrol[filecache]>0.12.6
Using cached CacheControl-0.12.11-py2.py3-none-any.whl (21 kB)
Collecting tqdm<5
Using cached tqdm-4.64.1-py2.py3-none-any.whl (78 kB)
Collecting colorama
Using cached colorama-0.4.6-py2.py3-none-any.whl (25 kB)
Collecting requests-toolbelt
Using cached requests_toolbelt-0.10.1-py2.py3-none-any.whl (54 kB)
Collecting requests<3
Using cached requests-2.28.2-py3-none-any.whl (62 kB)
Collecting schema
Using cached schema-0.7.5-py2.py3-none-any.whl (17 kB)
Collecting contextlib2>0.6.0
Using cached contextlib2-21.6.0-py2.py3-none-any.whl (13 kB)
Collecting requests-file
Using cached requests_file-1.5.1-py2.py3-none-any.whl (3.7 kB)
Collecting packaging
Using cached packaging-23.0-py3-none-any.whl (42 kB)
Collecting click
Using cached click-8.1.3-py3-none-any.whl (96 kB)
Collecting six
Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting msgpack>=0.5.2
Using cached msgpack-1.0.4-cp39-cp39-win_amd64.whl (62 kB)
Collecting lockfile>=0.9
Using cached lockfile-0.12.2-py2.py3-none-any.whl (13 kB)
Collecting pycparser
Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
Collecting charset-normalizer<4,>=2
Using cached charset_normalizer-3.0.1-cp39-cp39-win_amd64.whl (96 kB)
Collecting urllib3<1.27,>=1.21.1
Using cached urllib3-1.26.14-py2.py3-none-any.whl (140 kB)
Collecting idna<4,>=2.5
Using cached idna-3.4-py3-none-any.whl (61 kB)
Collecting certifi>=2017.4.17
Using cached certifi-2022.12.7-py3-none-any.whl (155 kB)
Installing collected packages: msgpack, lockfile, charset-normalizer, urllib3, six, pyyaml, pycparser, packaging, kconfiglib, idna, future, contextlib2, colorama, certifi, tqdm, schema, requests, click, cffi, requests-toolbelt, requests-file, cryptography, cachecontrol, idf-component-manager
Attempting uninstall: msgpack
Found existing installation: msgpack 1.0.4
Uninstalling msgpack-1.0.4:
Successfully uninstalled msgpack-1.0.4
Attempting uninstall: lockfile
Found existing installation: lockfile 0.12.2
Uninstalling lockfile-0.12.2:
Successfully uninstalled lockfile-0.12.2
Attempting uninstall: charset-normalizer
Found existing installation: charset-normalizer 3.0.1
Uninstalling charset-normalizer-3.0.1:
Successfully uninstalled charset-normalizer-3.0.1
ERROR: Could not install packages due to an OSError: [WinError 5] Access is denied: 'C:\\Users\\deckc\\.platformio\\penv\\Lib\\site-packages\\~=arset_normalizer\\md.cp39-win_amd64.pyd'
Check the permissions.
*** Error 1
Reading CMake configuration...
-- Found Git: C:/Program Files/Git/cmd/git.exe (found version "2.39.0.windows.2")
-- The C compiler identification is GNU 8.4.0
-- The CXX compiler identification is GNU 8.4.0
-- The ASM compiler identification is GNU
-- Found assembler: C:/Users/deckc/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/deckc/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/deckc/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: C:/Users/deckc/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-g++.exe
-- Check for working CXX compiler: C:/Users/deckc/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-g++.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Project is not inside a git repository, or git repository has no commits; will not use 'git describe' to determine PROJECT_VER.
-- Building ESP-IDF components for target esp32
-- Configuring incomplete, errors occurred!
See also "D:/Documents/PlatformIO/Projects/EspIdfTestProject/.pio/build/lolin_d32_pro/CMakeFiles/CMakeOutput.log".
fatal: not a git repository (or any of the parent directories): .git
CMake Error at C:/Users/deckc/.platformio/packages/framework-espidf/tools/cmake/build.cmake:452 (message):
C:\Users\deckc\.platformio\penv\Scripts\python.exe: Error while finding
module specification for 'idf_component_manager.prepare_components'
(ModuleNotFoundError: No module named 'idf_component_manager')
Call Stack (most recent call first):
C:/Users/deckc/.platformio/packages/framework-espidf/tools/cmake/project.cmake:384 (idf_build_process)
CMakeLists.txt:3 (project)
========================= [FAILED] Took 10.56 seconds ========================="
Can somebody help me out please I have done several restarts etc.