The root cause of this problem lies in the build process when build.cmake checks Python dependencies using the line:
execute_process(COMMAND "${python}" "${idf_path}/tools/idf_tools.py" "check-python-dependencies").
During this check, the idf_tools.py script assumes the .espressif folder and its required files (like espidf.constraints.v5.3.txt) are in the default user directory (e.g., C:\Users\[YourUsername]\.espressif). If this folder or file is missing, the build fails. This happens because the script defaults to looking in the user folder, regardless of where the actual ESP-IDF files are installed.
Solution
- Locate the file 
espidf.constraints.v5.3.txt in C:\Espressif\espidf.constraints.v5.3.txt or in the tools folder of your ESP-IDF installation. 
- Copy the file to the 
.espressif directory under your user folder (e.g., C:\Users\[YourUsername]\.espressif). 
- Right-click on your project in Visual Studio, select “Clean Project,” and the error should be resolved.
 
I tested it worked forme, Visualstudio 2019 and 2022
	- 
		This reply was modified 9 months, 2 weeks ago by 
maghsood.