Infra Go toolchain fails on Windows b/c of missing "cipd.exe". |
||
Issue descriptionThe problematic line is here: https://chromium.googlesource.com/infra/infra/+/4b231b956f3511b1b35379f8b6ce1eba341fb146/go/deps.py#466 On developer systems, "cipd" is available as "cipd.bat", not "cipd.exe". I think that this is also true on bots b/c "cipd_bootstrap_v2" generates a batch file for "cipd". Therefore, this should be safe to change to ".bat". In the meantime, Windows users get a stack trace like this: Searching for a bundle with dependencies in CIPD... -------------------------------------------------------------------------------- CIPD package name: infra/go-deps CIPD package version: go_deps_lock:30a48567fbc38996da712cb9909e62695abbf64f -------------------------------------------------------------------------------- Traceback (most recent call last): File "C:\Users\dnj\infra\infra\go\deps.py", line 811, in <module> sys.exit(main(sys.argv[1:])) File "C:\Users\dnj\infra\infra\go\deps.py", line 795, in main return install(workspace, opts.force, opts.update_out) File "C:\Users\dnj\infra\infra\go\deps.py", line 549, in install use_bundle = is_existing_bundle(workspace, pkg, ver) File "C:\Users\dnj\infra\infra\go\deps.py", line 494, in is_existing_bundle return cipd(workspace, ['resolve', pkg, '-version', ver], silent=True) == 0 File "C:\Users\dnj\infra\infra\go\deps.py", line 475, in cipd stderr=subprocess.PIPE if silent else None) File "C:\Users\dnj\infra\depot_tools\python276_bin\lib\subprocess.py", line 709, in __init__ errread, errwrite) File "C:\Users\dnj\infra\depot_tools\python276_bin\lib\subprocess.py", line 957, in _execute_child startupinfo) WindowsError: [Error 2] The system cannot find the file specified Traceback (most recent call last): File ".\go\env.py", line 101, in <module> main() File ".\go\env.py", line 83, in main deps_only=args.deps_only) File ".\go\bootstrap.py", line 617, in prepare_go_environ bootstrap(layout, logging.INFO) File ".\go\bootstrap.py", line 579, in bootstrap p, layout.toolset_root, force=toolset_updated) File ".\go\bootstrap.py", line 462, in update_vendor_packages subprocess.check_call(cmd, stdout=sys.stderr, env=env) File "C:\Users\dnj\infra\depot_tools\python276_bin\lib\subprocess.py", line 540, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['C:\\Users\\dnj\\infra\\depot_tools\\python276_bin\\python.exe', '-u', 'C:\\Users\\dnj\\infra\\infra\\go\\deps.py', '--workspace', 'C:\\Users\\dnj\\infra\\infra\\go', '--goroot', 'C:\\Users\\dnj\\ infra\\golang\\go', 'install', '--update-out', 'C:\\Users\\dnj\\infra\\infra\\go\\tmpx6yqus\\deps_updated.json']' returned non-zero exit status 1
,
Apr 21 2017
Yeah that makes perfect sense. However, when iannucci@ added the "cipd_bootstrap_v2", we standardized on ".bat" as the user-agnostic entry point. For pure-bot things ".exe" will still be fine, but for anything that may be run by a user or by a bot, we need to use ".bat" IIRC.
,
Apr 21 2017
It works on bots (both Buildbot and Swarming). Do buildbot bots have cipd.exe in PATH? Changing to *.bat should be ok. IIRC, we have *.bat everywhere now.
,
Apr 21 2017
BuildBot bots have ".exe" in path, as "cipd_bootstrap_v2" adds both the ".exe" and ".bat" files to PATH.
,
Apr 21 2017
,
Apr 21 2017
The following revision refers to this bug: https://chromium.googlesource.com/infra/infra/+/7ff150730a2da8e35c765cf93bb2c0c9cf513e79 commit 7ff150730a2da8e35c765cf93bb2c0c9cf513e79 Author: Dan Jacques <dnj@chromium.org> Date: Fri Apr 21 16:35:38 2017 Use "cipd.bat" instead of "cipd.exe" for toolchain "cipd.exe" isn't available by default in any user environment. On the other hand, "cipd.bat" should be available both in the "depot_tools" user environment and on bots. BUG= chromium:714152 TEST=None R=iannucci@chromium.org, vadimsh@chromium.org Change-Id: Ia4f2de1094331cb09fd9a86a8f6cde662fe74490 Reviewed-on: https://chromium-review.googlesource.com/483883 Reviewed-by: Vadim Shtayura <vadimsh@chromium.org> Commit-Queue: Daniel Jacques <dnj@chromium.org> [modify] https://crrev.com/7ff150730a2da8e35c765cf93bb2c0c9cf513e79/go/deps.py
,
Apr 21 2017
Confirmed working in developer environment and bots. https://uberchromegw.corp.google.com/i/chromium.infra/builders/infra-continuous-win-64/builds/6910 |
||
►
Sign in to add a comment |
||
Comment 1 by no...@chromium.org
, Apr 21 2017