[Error: No module named gdb] Debug start problem

On CLion, upon starting a debug for a Atmel 328P I get the following error:

Python Exception <type 'exceptions.ImportError'> No module named gdb: 

Could not load the Python gdb module from `/Users/jenkins/jenkins/workspace/avr-gcc-staging/label/mac-mini/objdir/share/gdb/python'.
Limited Python support is available from the _gdb module.
Suggest passing --data-directory=/path/to/gdb/data-directory.

Reading symbols from /Users/wirepirate/CLionProjects/LEDInterval/.pio/build/uno/firmware.elf...done.
PlatformIO Unified Debugger -> https://bit.ly/pio-debug
PlatformIO: debug_tool = custom
PlatformIO: Initializing remote target...

How do I solve this error? I’m using macOS.

Does debugging still work without it?

Report to Issues · platformio/platform-atmelavr · GitHub.

I replaced the PIO shipped AVR-GDB with the one from Homebrew. The error is gone, so it seems to be a problem in the PIO build.

Can you explain how you did this? I have the same problem and am also on a Mac, thanks!

Does it prevent debugging or is just in the log with no further consequences?

it prevents debugging

Sorry my bad, it does not prevent debugging, I didn’t setup debug_port properly.
So I get that error but I still can debug.