diff --git a/src/plugins/python/pythonrunconfiguration.cpp b/src/plugins/python/pythonrunconfiguration.cpp index 12141ba1a93..30e85439b5c 100644 --- a/src/plugins/python/pythonrunconfiguration.cpp +++ b/src/plugins/python/pythonrunconfiguration.cpp @@ -8,6 +8,7 @@ #include "pysidebuildconfiguration.h" #include "pysideuicextracompiler.h" #include "pythonconstants.h" +#include "pythonkitaspect.h" #include "pythonlanguageclient.h" #include "pythonproject.h" #include "pythonsettings.h" @@ -365,6 +366,9 @@ public: x11Forwarding.setMacroExpander(macroExpander()); x11Forwarding.setVisible(HostOsInfo::isAnyUnixHost()); + if (const std::optional kitPython = PythonKitAspect::python(target->kit())) + interpreter.setCurrentInterpreter(*kitPython); + setCommandLineGetter([this] { CommandLine cmd{interpreter.currentInterpreter().command}; if (!buffered())