Why does "dbt deps" command gives error - Got a non-zero returncode running

1.3k Views Asked by At

I was configuring DBT and when I ran "dbt deps" command end up with an below error

Running with dbt=0.20.0
Encountered an error:
Got a non-zero returncode running: ['C:\\Program Files\\Git\\cmd\\git.EXE', 'clone', '--depth', '1', 'https://dev.azure.com/XYZ/z1', '8d432d9f6809c664']

May I know the reason and how to resolve this?

1

There are 1 best solutions below

0
Anders Swanson On

It looks like the package you are trying to install is a private repo on Azure DevOps. You will need to authenticate to have that repo cloned.

the Private Repo section of the Packages dbt docs page, even has a section on how to clone private repos on Azure DevOps (copied here below for posterity). You'll need to make an environment variable for the ADO Personal Access Token.

packages:
  - git: "https://{{env_var('DBT_ENV_SECRET_PERSONAL_ACCESS_TOKEN')}}@dev.azure.com/dbt-labs/awesome_project/_git/awesome_repo" # git HTTPS URL