[foozzie] Fix arguments in wrapper

No-Try: true
Bug: chromium:1288926
Change-Id: Ie28021a34649aeaa68c34252ffe181163a7df2ae
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3568466
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Liviu Rau <liviurau@chromium.org>
Commit-Queue: Liviu Rau <liviurau@chromium.org>
Cr-Commit-Position: refs/heads/main@{#79740}
This commit is contained in:
Michael Achenbach 2022-04-04 14:23:49 +02:00 committed by V8 LUCI CQ
parent 5a7ed57b10
commit 307e30c1eb

View File

@ -18,6 +18,14 @@ import subprocess
import sys
if __name__ == '__main__':
# In some cases or older versions, the python executable is passed as
# first argument. Let's be robust either way, with or without full
# path or version.
if re.match(r'.*python.*', sys.argv[1]):
args = sys.argv[2:]
else:
args = sys.argv[1:]
process = subprocess.Popen(['python3'] + args)
process = subprocess.Popen(args)
process.communicate()
sys.exit(process.returncode)