CLion 2020.3.2 Error during pretty printers setup: Error while executing Python code
Answered
I cannot access the C++ debugger on CLion 2020.3.2. Error message is
Error during pretty printers setup: Error while executing Python code.
Some features and performance optimizations will not be available.
C:\Users\David\Documents\CLionProjects\SocialDistancing\cmake-build-debug\SocialDistancing.exe
Process finished with exit code 1
I have looked around the community and tried some of the common solutions such as reinstalling MinGW, it does not resolve the issue. See picture below for my Toolchains:
Code to reproduce the problem:
#include <iostream>
#include <vector>
using namespace std;
int divide(int first, int last, vector<int>& pic, int p){
//
//int mid = (last-first)/2;
return 0;
}
int main() {
int n = 0, p = 0;
cin >> n;
cin >> p;
vector<int> pos(n);
for(int i = 0; i < n; i++)
{
cin >> pos[i];
}
return 0;
}
It doesn't seem to be this code specifically. I tried multiple different C++ projects or even empty ones but they have refused to work with the same error message. Thanks all!
Please sign in to leave a comment.
Hello!
It's https://youtrack.jetbrains.com/issue/CPP-23244, sorry for the inconvenience. The issue is fixed in CLion 2021.1 EAP (https://www.jetbrains.com/clion/nextversion/), please try using it.
Hi,
Still have the same issues with 2021.2.1
As soon I make a call to a static method in another class, CLion stops the process.
Nik It looks like the GDB being used was not built with Python support, which is necessary for pretty printers to work.
Do you use MinGW toolchain? If yes, you need to install the MinGW-w64 distribution which includes GDB built with Python support. This one (https://www.mingw-w64.org/downloads/#mingw-builds, the "Mingw-builds" section) should be suitable.
Thank you for your quick response Anna, I'll try that and let you know