I think I have a corrupt c_cpp_propteries.json file

this error message pops up during VS code PIO startup{
“resource”: “/c:/Users/Carl/Documents/PlatformIO/Projects/Teensy_sequencer_V2/.vscode/c_cpp_properties.json”,
“owner”: “c:\Users\Carl\Documents\PlatformIO\Projects\Teensy_sequencer_V2”,
“severity”: 4,
“message”: “Cannot find “C:\Users\Carl\.platformio\packages\toolchain-gccarmnoneeabi@1.50401.190816\bin\arm-none-eabi-gcc.exe”.”,
“startLineNumber”: 255,
“startColumn”: 29,
“endLineNumber”: 255,
“endColumn”: 131
}
when I try to compile i get ModuleNotFoundError ‘elftools’ :

Can you post the full error log that appears when you do the “Build” task?

here is the terminal window response.

ModuleNotFoundError: No module named 'elftools':
  File "C:\Users\Carl\.platformio\penv\lib\site-packages\platformio\builder\main.py", line 91:
    env = DefaultEnvironment(**DEFAULT_ENV_OPTIONS)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Defaults.py", line 86:
    _default_env = SCons.Environment.Environment(*args, **kw)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 999:
    apply_tools(self, tools, toolpath)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 102:
    env.Tool(tool)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 1843:
    tool = SCons.Tool.Tool(tool, toolpath, **kw)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Tool\__init__.py", line 119:
    module = self._tool_module()
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Tool\__init__.py", line 205:
    module = spec.loader.load_module(spec.name)
  File "<frozen importlib._bootstrap_external>", line 407:
    
  File "<frozen importlib._bootstrap_external>", line 907:
    
  File "<frozen importlib._bootstrap_external>", line 732:
    
  File "<frozen importlib._bootstrap>", line 265:
    
  File "<frozen importlib._bootstrap>", line 696:
    
  File "<frozen importlib._bootstrap>", line 677:
    
  File "<frozen importlib._bootstrap_external>", line 728:
    
  File "<frozen importlib._bootstrap>", line 219:
    
  File "C:\Users\Carl\.platformio\penv\lib\site-packages\platformio\builder\tools\piosize.py", line 23:
    from elftools.elf.descriptions import describe_sh_flags

Can you please first remove all folders C:\Users\Carl\.platformio\packages\toolchain-gccarmnoneeabi* completely and press “Build” again?

Otherwise your PlatformIO installation looks broken and I’ll post a link to a reinstallation guide if that does not help.

Thanks Maxgerhardt, I will try and let you know shortly
looks like similar issue

Tool Manager: Installing platformio/toolchain-gccarmnoneeabi @ ~1.50401.0
Downloading  [####################################]  100%
Unpacking  [####################################]  100%
Tool Manager: toolchain-gccarmnoneeabi @ 1.50401.190816 has been installed!
ModuleNotFoundError: No module named 'elftools':
  File "C:\Users\Carl\.platformio\penv\lib\site-packages\platformio\builder\main.py", line 91:
    env = DefaultEnvironment(**DEFAULT_ENV_OPTIONS)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Defaults.py", line 86:
    _default_env = SCons.Environment.Environment(*args, **kw)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 999:
    apply_tools(self, tools, toolpath)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 102:
    env.Tool(tool)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 1843:
    tool = SCons.Tool.Tool(tool, toolpath, **kw)
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Tool\__init__.py", line 119:
    module = self._tool_module()
  File "C:\Users\Carl\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Tool\__init__.py", line 205:
    module = spec.loader.load_module(spec.name)
  File "<frozen importlib._bootstrap_external>", line 407:
    
  File "<frozen importlib._bootstrap_external>", line 907:
    
  File "<frozen importlib._bootstrap_external>", line 732:
    
  File "<frozen importlib._bootstrap>", line 265:
    
  File "<frozen importlib._bootstrap>", line 696:
    
  File "<frozen importlib._bootstrap>", line 677:
    
  File "<frozen importlib._bootstrap_external>", line 728:
    
  File "<frozen importlib._bootstrap>", line 219:
    
  File "C:\Users\Carl\.platformio\penv\lib\site-packages\platformio\builder\tools\piosize.py", line 23:
    from elftools.elf.descriptions import describe_sh_flags
================================================================== [FAILED] Took 61.60 seconds ==================================================================
The terminal process "C:\Users\Carl\.platformio\penv\Scripts\pio.exe 'run', '--environment', 'teensy41'" terminated with exit code: 1.

Please do the following:

  1. Open a PlatformIO CLI
  2. Execute pio upgrade --dev
  3. Execute pio platform update
  4. Restart VSCode
  5. Rebuild the project.

If that does not work, it’s re-install time.

ok thanks, I’ll need to figure out how to do the Command line stuff as the cli is not an option under Miscellaneous on my installation

I just use the terminal correct?

If that’s the case then your PlatformIO installation seems heavily outdated.

Please do the following:

  1. In VSCode, remove the PlatformIO extension
  2. Remove the folder C:\Users\Carl\.platformio\ completely
  3. Reinstall the PlatformIO VSCode extension from the marketplace, wait for installation, then restart VSCode
  4. Rebuild project

OK Max, Thanks will do

Max,reload and rebuild worked Thankyou !!