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. Dismiss Notice

Question Packagemanager cannot add the package by git url

Discussion in 'Package Manager' started by NeverTrustShadows, Nov 12, 2020.

  1. NeverTrustShadows

    NeverTrustShadows

    Joined:
    Mar 15, 2020
    Posts:
    13
    Public and Private keys are added and regular git operations seem to be working fine. It seems that unity is somehow not aware of my credentials or something like that. I get the following error every time I tried.

    Cannot perform upm operation: Unable to add package [https://gitlab.com/#/common.git]:
    Error when executing git command. remote: HTTP Basic: Access denied
    fatal: Authentication failed for 'https://gitlab.com/#/common.git/'
    [NotFound]
    UnityEditor.EditorApplication:Internal_CallUpdateFunctions()
     
  2. SushiWaUmaiyo

    SushiWaUmaiyo

    Joined:
    Jun 5, 2019
    Posts:
    2
    Having the same issue.
     
  3. Adrian

    Adrian

    Joined:
    Apr 5, 2008
    Posts:
    1,051
    The Unity manual for git dependencies has some pointers for authentication.

    Note that it's a HTTP Basic authentication error, which uses login/password and not your SSH keys. Did you add your git dependency using the git or http url? If you want to use SSH keys, you need to use the git url.

    If you want to use the HTTP git url, you need to authenticate with a git credentials helper, Unity cannot ask you for your login/password interactively.

    If you're already using the git url, LFS can still try to connect using HTTP. Check the documentation above for how to tell Unity the LFS url to use.
     
    maximeb_unity likes this.