Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There was an error processing your request: Could not analyze the repository: no .go files found #359

Closed
AchoArnold opened this issue Nov 20, 2021 · 17 comments

Comments

@AchoArnold
Copy link

The repository has .go files all over. https://github.com/NdoleStudio/flutterwave-go

What am I doing wrongly?

image

@kozgot
Copy link

kozgot commented Nov 20, 2021

I have the same error for my repository.
image

For me, the report card was working originally without a problem as you can see on the screenshot (Last refresh: 1 week ago), but last Wednesday (17/11/2021) I could not refresh it because of this error, and it has not been fixed since. I have not changed anything in my repo or code that would cause this behaviour. The cli tool works just fine for me:
image

@YashdalfTheGray
Copy link

This could potentially be related to #357, have you switched your branch name recently? I think that's the problem that I'm having.

https://goreportcard.com/report/github.com/YashdalfTheGray/colorcode

@kozgot
Copy link

kozgot commented Nov 21, 2021

No, I have not switched my branch name.

@shawnps
Copy link
Contributor

shawnps commented Nov 21, 2021

@kozgot I believe your issue may be because there's no go.mod in the root of your repo.

The other issues are likely due to a case-sensitivity bug (try https://proxy.golang.org/github.com/YashdalfTheGray/colorcode/@latest vs https://proxy.golang.org/github.com/yashdalfthegray/colorcode/@latest and you can see it) I'm investigating but unfortunately can't guarantee when it will be fixed.

@shawnps
Copy link
Contributor

shawnps commented Nov 21, 2021

@AchoArnold @YashdalfTheGray your repos seem to be working now, let me know if you notice any more issues 👍

@kozgot
Copy link

kozgot commented Nov 21, 2021

@shawnps, yes because this repository contains the code of 3 individual microservices, so the go.mod files are in subdirectories, however as I wrote before, the issue only occured about a week ago, before that everything worked fine. And the cli tool also works fine currently, and I have not changed the project structure, so I do not see any reason as to why this error appeared out of nowhere.

@shawnps
Copy link
Contributor

shawnps commented Nov 21, 2021

@kozgot we're now using proxy.golang.org to download the latest module (as of about a week ago) rather than git cloning, which likely explains it.

@kozgot
Copy link

kozgot commented Nov 21, 2021

@shawnps Can you recommend a way to make it work again? This is a university project for me, and the due date is very close now, so I really do not want to split the code into multiple repos.

@shawnps
Copy link
Contributor

shawnps commented Nov 21, 2021

@kozgot would go mod init github.com/kozgot/go-log-processing in the root not work?

@YashdalfTheGray
Copy link

@AchoArnold @YashdalfTheGray your repos seem to be working now, let me know if you notice any more issues 👍

Yay! Thanks! Out of curiosity, what was the issue? No worries if you don't have time to get into it and sorry for interrupting the conversation flow.

@shawnps
Copy link
Contributor

shawnps commented Nov 23, 2021

@YashdalfTheGray no worries!

The issue was: we used to use git to pull down repositories and run the checks. But we recently switched to downloading .zip files containing the module contents from proxy.golang.org.

proxy.golang.org rejects module names with uppercase letters (see the links I posted in #359 (comment)). So we just needed to lowercase the module name before requesting the module contents from the proxy.

Hope that helps 👍

@kozgot
Copy link

kozgot commented Nov 23, 2021

@shawnps I did not have the time to look into it yet, but certainly will. Thank you for the suggestion.

@shawnps
Copy link
Contributor

shawnps commented Nov 23, 2021

@kozgot sure, let me know how it goes.

@AchoArnold
Copy link
Author

Its all good from my end. Can i close the ticket?

@shawnps
Copy link
Contributor

shawnps commented Nov 23, 2021

@AchoArnold sure, thanks for reporting 👍

@TomiwaAribisala-git
Copy link

TomiwaAribisala-git commented Nov 7, 2023

Hello, @shawnps @hermanschaaf apologies for opening up this issue, I am having a similar problem generating a GoReportCard for KubeArmor project, i must point out that the root source code does not have a go.mod file--going forward i intend to do go mod init https://github.com/kubearmor/KubeArmor in the root as indicated in your comment and see if i can generate a report card.

Also i checked the project repo via proxy.golang.org using lowercaseletters(https://github.com/kubearmor/kubearmor), the picture output was generated below:
download

I await your favorable response, thanks

@shawnps
Copy link
Contributor

shawnps commented Nov 11, 2023

@TomiwaAribisala-git sorry for the late response.

Go Report Card downloads .zip files of source code from proxy.golang.org.

If you download this file:

http://proxy.golang.org/github.com/kubearmor/kubearmor/@v/v1.0.3.zip

You'll notice that there are no .go files.

I'm not sure why that's happening (maybe like you said because there's no go.mod file in the root), but that would be why GRC returns an error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants