gojp / goreportcard

A report card for your Go application
https://goreportcard.com
Apache License 2.0
1.99k stars 252 forks source link

could not get latest module version: no matching versions for query "latest" #427

Open HaraldNordgren opened 1 month ago

HaraldNordgren commented 1 month ago

This is happening when trying to refresh this repo. It hasn’t been refreshed for 2 years:

https://goreportcard.com/report/github.com/elastic/go-elasticsearch

There was an error processing your request: Could not analyze the repository: could not download repo: could not get latest module version from https://proxy.golang.org/github.com/elastic/go-elasticsearch/@latest: not found: module github.com/elastic/go-elasticsearch: no matching versions for query "latest"
oCHRISo commented 3 weeks ago

Plus 1 for the same issue but with a different repo.

When trying to generate a report on https://goreportcard.com/ for the repo https://github.com/nginx/agent I get the below error

Screenshot 2024-08-21 at 07 15 01
shawnps commented 3 weeks ago

@oCHRISo it seems the issue is the module name:

https://github.com/nginx/agent/blob/main/go.mod#L1

https://goreportcard.com/report/github.com/nginx/agent/v2

For reference, if it doesn't show up on pkg.go.dev, it most likely won't show up in Go Report Card, because we're using proxy.golang.org to download the repos:

https://pkg.go.dev/search?q=github.com%2Fnginx%2Fagent&m=

shawnps commented 3 weeks ago

@HaraldNordgren I think it's a similar issue, please try github.com/elastic/go-elasticsearch/v8:

https://goreportcard.com/report/github.com/elastic/go-elasticsearch/v8

lordofscripts commented 2 weeks ago

I am getting a similar issue. I got it working somehow on a previous repository that is NOT on pkg.go.dev but on this new one it just doesn't work. It shows the results of the first run from 3 days ago but despite having fixed the format issues, this is still reporting badly:

https://goreportcard.com/report/github.com/lordofscripts/wipechromium