New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 780554 link

Starred by 2 users

Issue metadata

Status: Duplicate
Merged: issue 778370
Owner:
Last visit > 30 days ago
Closed: Nov 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 3
Type: Bug



Sign in to add a comment

Rebuilding //remoting/webapp on windows fails with WindowsError

Project Member Reported by pbos@chromium.org, Nov 1 2017

Issue description

Repro steps for me is to work a while, then git pull --rebase and gclient sync about a week later.

[2068/22923] ACTION //remoting/webapp:webapp(//build/toolchain/win:win_clang_x86)
FAILED: remoting-webapp.v2.zip
C:/src/depot_tools/win_tools-2_7_6_bin/python/bin/python.exe ../../remoting/webapp/build-webapp.py Dev 64.0.3256.0 remoting/remoting-webapp.v2 remoting-webapp.v2.zip ../../remoting/webapp/crd/manifest.json.jinja2 --files_listfile gen/remoting/webapp/webapp_files.txt --locales_listfile gen/remoting/webapp/webapp_locales.txt --use_gcd 0
Traceback (most recent call last):
  File "../../remoting/webapp/build-webapp.py", line 380, in <module>
    sys.exit(main())
  File "../../remoting/webapp/build-webapp.py", line 376, in main
    return buildWebApp(**vars(args))
  File "../../remoting/webapp/build-webapp.py", line 233, in buildWebApp
    replaceString(destination, 'DIRECTORY_API_BASE_URL', directoryApiBaseUrl)
  File "../../remoting/webapp/build-webapp.py", line 63, in replaceString
    "'" + placeholder + "'", "'" + value + "'")
  File "../../remoting/webapp/build-webapp.py", line 41, in findAndReplace
    os.rename(filepath, oldFilepath)
WindowsError: [Error 183] Cannot create a file when that file already exists
[2227/22923] CXX obj/components/policy/chrome_settings_proto_generated_compile_proto/chrome_settings.pb.obj

os.rename python documentation says: On Windows, if dst already exists, OSError will be raised even if it is a file; there may be no way to implement an atomic rename when dst names an existing file.

.. so filepath probably has to be removed if the file already exists, which is what I end up doing to mitigate this build error.
 

Comment 1 by w...@chromium.org, Nov 1 2017

Owner: jamiewa...@chromium.org
Owner: zijiehe@chromium.org
Status: Assigned (was: Unconfirmed)
Zijie, this looks like the same as bug 778370; can you verify and close this as a dupe if you agree?
Mergedinto: 778370
Status: Duplicate (was: Assigned)
This should have be fixed already, see bug 778370 for details.

Sign in to add a comment