summaryrefslogtreecommitdiff
path: root/src/plugins/python/pythonlanguageclient.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/python/pythonlanguageclient.cpp')
-rw-r--r--src/plugins/python/pythonlanguageclient.cpp19
1 files changed, 0 insertions, 19 deletions
diff --git a/src/plugins/python/pythonlanguageclient.cpp b/src/plugins/python/pythonlanguageclient.cpp
index fcf1d86b9e..c4b01462ea 100644
--- a/src/plugins/python/pythonlanguageclient.cpp
+++ b/src/plugins/python/pythonlanguageclient.cpp
@@ -77,25 +77,6 @@ struct PythonLanguageServerState
FilePath pylsModulePath;
};
-static QString pythonName(const FilePath &pythonPath)
-{
- static QHash<FilePath, QString> nameForPython;
- if (!pythonPath.exists())
- return {};
- QString name = nameForPython.value(pythonPath);
- if (name.isEmpty()) {
- QtcProcess pythonProcess;
- pythonProcess.setTimeoutS(2);
- pythonProcess.setCommand({pythonPath, {"--version"}});
- pythonProcess.runBlocking();
- if (pythonProcess.result() != ProcessResult::FinishedWithSuccess)
- return {};
- name = pythonProcess.allOutput().trimmed();
- nameForPython[pythonPath] = name;
- }
- return name;
-}
-
FilePath getPylsModulePath(CommandLine pylsCommand)
{
static QMutex mutex; // protect the access to the cache