Then with “pio run --target envdump” from PlatformIO CLI within vscode I see:-
‘BUILD_FLAGS’: [’-std=c++17 -std=gnu++17’]
But if I try this:-
platformio.ini
build_flags = ! getflags.py
All I get is:-
‘BUILD_FLAGS’: [’! getflags.py’]
So clearly the python getflags.py is not being executed.
The getflags.py is in the same folder as platformio.ini.
Using the full path for getflags.py doesn’t work either.
I have ‘PYTHONEXE’: ‘C:\Users\my_user\.platformio\penv\Scripts\python.exe’.
When I compile the project, build_flags is clearly not set with the expected cpp flags.
I see from another post that someone else has win10+vscode+platformio working for executing python scripts within the platformio.ini, so wondering what could be wrong with my setup?