From e8033df81ecde6baec2e7f69027827e4ee726939 Mon Sep 17 00:00:00 2001 From: Ines Montani Date: Mon, 29 Jun 2020 20:30:42 +0200 Subject: [PATCH] Also handle python3 and pip3 --- spacy/cli/project.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spacy/cli/project.py b/spacy/cli/project.py index 27dc83e29..1bb92f749 100644 --- a/spacy/cli/project.py +++ b/spacy/cli/project.py @@ -595,9 +595,9 @@ def run_commands( command = command.format(**variables) command = shlex.split(command) # TODO: is this needed / a good idea? - if len(command) and command[0] == "python": + if len(command) and command[0] in ("python", "python3"): command[0] = sys.executable - elif len(command) and command[0] == "pip": + elif len(command) and command[0] in ("pip", "pip3"): command = [sys.executable, "-m", "pip", *command[1:]] if not silent: print(" ".join(command))