Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-20380

Go (v1.13+) go get from github returns a bad pre release version names

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.16.0
    • Component/s: Go
    • Labels:

      Description

      Starting from go 1.13, validation was added to the version names when requesting info files.

      Getting go prerelease version now fails on cases info file was created from GitHub, because the requested info file contained only the hash of the commit as the Version property.
      correct syntax is v0.0.0-{timestamp}-{commit-hash}. returned syntax is {commit-hash}

      go list -m github.com/alecthomas/template@v0.0.0-20160405071501-a0175ee3bccc 
      go: finding github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc go list -m: github.com/alecthomas/template@v0.0.0-20160405071501-a0175ee3bccc: proxy returned info for version a0175ee3bccc instead of requested version
      

      This happens because of the info file is wrong: 

      curl https://entplus.jfrog.io/artifactory/api/go/go/github.com/alecthomas/template/@v/v0.0.0-20160405071501-a0175ee3bccc.info 
      
      {"name":"a0175ee3bccc567396460bf5acd36800cb10c49c","shortName":"a0175ee3bccc","version":"a0175ee3bccc","time":"2016-04-05T07:15:01Z"}
      
      going to default go proxy (or not using GOPROXY) will return this version with
      {"Version":"v0.0.0-20161220082320-a0175ee3bccc","Time":"2016-12-20T08:23:20Z"}
      

      (name and shortName are omitted)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                nadavy Nadav Yogev
                Reporter:
                nadavy Nadav Yogev
                Assigned QA:
                Andrey Tashlitsky
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: