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
logcheck: should not return error if no Go files are present #214
Comments
/good-first-issue |
@adisky: Please ensure the request meets the requirements listed here. If this request no longer meets these requirements, the label can be removed In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/assign |
@ehashman is problem mitigated by running linter against parent directories? For example now we run against |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-contributor-experience at kubernetes/community. |
This issue blocks kubernetes/kubernetes/issues/102439 which is targeted for v1.22. /remove-lifecycle stale |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
I would like to look into this 🤓 /assign |
/assign @daemon1024 |
Hey @daemon1024 can you please give us a rough estimate as in how much time it will require to come up with a fix for this? |
/priority important-soon |
/remove-priority important-longterm |
@shivanshu1333 I have went through the relevant discussions. I am currently in process of setting up and reproducing it. I will have a fix or some concrete update by the end of the week. |
That's awesome, thanks! |
Hello, Apologies for the delay. As pointed out in #220 (comment), we can't depend on analyzer main function since it directly exits. So we need our own validation logic. From #220 (comment)
So I rewrote the logic in the PR more in line with what this comment suggested. Here's the link to the commit daemon1024@fe26f9b The caveat here is that we will be loading packages twice. The other way to handle the validation is, we walk through the directory to check if there are any go files present there or not. Here's the commit daemon1024@71d4862 using file walk. I understand sharing commits is not the right way to ask for review but I wanted to confirm which of the methods should I proceed with before raising a PR. |
@daemon1024 Feel free to raise a PR, there is no harm in raising the PR |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
fixed by kubernetes/kubernetes#108159 /close |
@liggitt: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/kind bug
What steps did you take and what happened:
When running logcheck against a directory that contains no Go files, I get an error:
What did you expect to happen:
I would expect a directory with no Go files to pass the linter.
Anything else you would like to add:
/cc @adisky
/priority important-longterm
The text was updated successfully, but these errors were encountered: