mirror of
https://github.com/gristlabs/grist-core.git
synced 2024-10-27 20:44:07 +00:00
fix type issue if python is missing when running unsandboxed (#610)
Clean up a small recently introduced type issue.
This commit is contained in:
parent
2e4a8ab8e0
commit
016ab66ea0
@ -999,7 +999,7 @@ const FAKETIME = '2020-01-01 00:00:00';
|
||||
* Find a plausible version of python to run, if none provided.
|
||||
* The preferred version is only used if command is not specified.
|
||||
*/
|
||||
function findPython(command: string|undefined, preferredVersion?: string) {
|
||||
function findPython(command: string|undefined, preferredVersion?: string): string {
|
||||
if (command) { return command; }
|
||||
// No command specified. In this case, grist-core looks for a "venv"
|
||||
// virtualenv; a python3 virtualenv would be in "sandbox_venv3".
|
||||
@ -1028,6 +1028,7 @@ function findPython(command: string|undefined, preferredVersion?: string) {
|
||||
return pythonPath;
|
||||
}
|
||||
}
|
||||
throw new Error('Cannot find Python');
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user