google-cloud-ops-agents-ansible icon indicating copy to clipboard operation
google-cloud-ops-agents-ansible copied to clipboard

Please delete branch "1.0.6" (HTTP Error 300: Multiple Choices)

Open MichaelGissingNC opened this issue 2 years ago • 0 comments

Description

I wanted to use 1.0.6, but I get a HTTP error: [ERROR]: failed to download the file: HTTP Error 300: Multiple Choices

Reproduction

  1. Have this requirements in requirements.yml:
roles:
 - name: googlecloudplatform.google_cloud_ops_agents
   version: 1.0.6
  1. Run the command ansible-galaxy install -r requirements.yml --force
  2. Get the following error:
Starting galaxy role install process
- downloading role 'google_cloud_ops_agents', owned by googlecloudplatform
- downloading role from https://github.com/GoogleCloudPlatform/stackdriver-ansible-role/archive/1.0.6.tar.gz
 [ERROR]: failed to download the file: HTTP Error 300: Multiple Choices
[WARNING]: - googlecloudplatform.google_cloud_ops_agents was NOT installed successfully.
ERROR! - you can use --ignore-errors to skip failed roles and finish processing the list.
  1. If you use curl, you see that it has 2 options to serve the reference 1.0.6 for this URL:
~$ curl "https://github.com/GoogleCloudPlatform/google-cloud-ops-agents-ansible/archive/1.0.6.tar.gz"
the given path has multiple possibilities: #<Git::Ref:0x00007f805cda8a98>, #<Git::Ref:0x00007f805cda85c0>
~$ 

Resolution

I guess this is caused by the existence of a git tag 1.0.6 and a git branch 1.0.6. As the branch won't be needed in my opinion, could you please delete it?

Workaround

  • Use ansible-galaxy install googlecloudplatform.google_cloud_ops_agents as it will download master.
  • Use version: master in requirements.yml

MichaelGissingNC avatar Jan 04 '23 16:01 MichaelGissingNC