Skip to content

feat: Add linter to check for potentially hanging tests #1649

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

Merged
merged 10 commits into from
Jul 11, 2025

Conversation

antitree
Copy link
Contributor

During the QEMU migration, we noticed that packages that have a pattern like so:

hostpathplugin --v=5 --endpoint="unix:///csi/csi.sock" --nodeid="node-000000" & sleep 5

Create a potential for an infinite hang during tests. This linter provides a WARNING if that is detected to give users a hint in the case this happens to fail a build.

@antitree antitree requested a review from egibs July 2, 2025 17:33
@antitree
Copy link
Contributor Author

antitree commented Jul 2, 2025

Factored in your changes @egibs and did some reviews for false positives. Based on the wolfi-dev/os from 30 days ago, it catches many of the issues.

@egibs egibs requested a review from stevebeattie July 2, 2025 19:56
@antitree antitree requested review from stevebeattie and removed request for stevebeattie July 7, 2025 17:28
@stevebeattie
Copy link
Member

This is good stuff, but I'm not sure how much the wolfictl linter is actively developed and is preferred; it seems more work on package source linting is done in melange's pkg/linter/ itself.

@justinvreeland
Copy link
Member

package source linting is done in melange's pkg/linter/ itself.

I don't think melange linter does any package source (yaml file) linting (though it probably should). At least looking a the melange I have installed now it only lists things that would impact built packages.

Copy link
Member

@egibs egibs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for a first pass; we can always iterate and refine this as we fix/find more edge cases.

It would be nice to get approval from the OS team as well.

@antitree antitree merged commit b4c3bf9 into wolfi-dev:main Jul 11, 2025
5 checks passed
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

Successfully merging this pull request may close these issues.

4 participants