Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Mercurial failed to clone error, http authorization required

Discussion in 'Unity Build Automation' started by apolotary, Oct 15, 2015.

  1. apolotary

    apolotary

    Joined:
    Feb 26, 2015
    Posts:
    11
    Hello,

    I'm trying to setup a Unity Cloud Build with my own server running Mercurial, and I'm getting failed to clone error, even though the username I provided works fine and I could establish connection to the server when setting up the builds. Also, the branch I'm using is the default one, so there's no problem with that.

    The log says http authorization required, however I did provide the username and password and I'm not sure why cloud build system is not using it.

    Any suggestions on how to troubleshoot this issue?

    Here's the full log:


    1: Running Prebuild steps
    2: done.
    3: bvr 1.1.0
    4: bvr-api 0.1.5
    5: $ hg clone --rev default --noupdate (edited out server url) /BUILD_PATH/(edited out the build path)
    6: abort: http authorization required for (edited out server url)
    7: ERROR: Failed to clone (edited out server url)
    8: ERROR: Failed to clone (edited out server url)
    9: postbuildstatus finished successfully.
    10: ls: Library: No such file or directory
    11: Deleting project workspace...
    12: Finished: FAILURE
    Status: FAILED​
     
  2. patrickc

    patrickc

    Unity Technologies

    Joined:
    Jan 23, 2015
    Posts:
    67
    Sometimes a source control host (like Bitbucket) will be having a bad day and attempts to clone during the build process will fail. It usually comes back after an hour or so. Is this happening all the time, or just a few times?

    Cheers,
    Patrick
     
  3. apolotary

    apolotary

    Joined:
    Feb 26, 2015
    Posts:
    11
    Sadly it's been happening ever since I set up my project three days ago. I tried re-entering URL and credentials after every failed build too. Another thing is that I also tried including username or username: password in the URL, but the Unity Cloud Build resets it every time as well.
     
  4. boolean01

    boolean01

    Joined:
    Nov 16, 2013
    Posts:
    90
    I had a lot of troubles getting source control to work with Mercurial. I can't find the original thread, but it was suggested elsewhere to try using the beta: https://build-beta.cloud.unity3d.com.

    Using the beta solved three issues for me:
    1) I couldn't use any URL that contained a username (eg. https://username@bitbucket.org/mainrepo/projectname).
    2) I couldn't change the source control settings once they were saved (meaning I couldn't change the user I had assigned)
    3) I couldn't change to a branch other than default (which yours is using anyway).

    Give it a shot, it might fix your problems.
     
  5. apolotary

    apolotary

    Joined:
    Feb 26, 2015
    Posts:
    11
    Thanks for the suggestion! Unfortunately I'm getting the same clone error on beta version
     
  6. dcarrigg

    dcarrigg

    Joined:
    May 21, 2014
    Posts:
    24
    Just curious if you've been able to fix this issue. I'm having the exact same one currently.

    Thanks