mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Upgrade to Python 3.11
Summary: Replaced mentions of Python 3.9 with 3.11 Test Plan: this Reviewers: paulfitz, georgegevoian Reviewed By: paulfitz, georgegevoian Subscribers: dsagal, georgegevoian, paulfitz Differential Revision: https://phab.getgrist.com/D3980
This commit is contained in:
@@ -1021,9 +1021,13 @@ function findPython(command: string|undefined, preferredVersion?: string) {
|
||||
}
|
||||
}
|
||||
// Fall back on system python.
|
||||
return which.sync(preferredVersion === '2' ? 'python2' : 'python3', {nothrow: true})
|
||||
|| which.sync(preferredVersion === '2' ? 'python2.7' : 'python3.9', {nothrow: true})
|
||||
|| which.sync('python');
|
||||
const systemPrefs = preferredVersion === '2' ? ['2.7', '2', ''] : ['3.11', '3.10', '3.9', '3', ''];
|
||||
for (const version of systemPrefs) {
|
||||
const pythonPath = which.sync(`python${version}`, {nothrow: true});
|
||||
if (pythonPath) {
|
||||
return pythonPath;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user