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

Suppress pmd's UnusedImport and UnnecessaryParens and allow pushing without PMD's approval #9

Merged
merged 9 commits into from
Feb 23, 2024

Conversation

Jakobeha
Copy link
Contributor

You will need to rm .git/hooks/pre-push to push without running mvn verify. The PMD tests and other static analyses will still run on GitHub actions, but it will also check tests without analyses, and let you merge regardless of whether any checks fail.

so we can see if something fails static analyses but passes tests, in case we want to resolve them later
There are still a couple warnings:

- A couple null checks which are immediately apparent but VSCode can't decide. If this is an issue, we should disable null analysis entirely on VSCode.
- "The hierarchy of type X is inconsistent" but it compiles fine. This seems to be an Eclipse/VSCode issue and I think the only way to resolve is to simplify inheritance, but idk if it's worth it since this only shows up in analysis.

Also, VSCode seems to change the non-null settings on startup which caused the warnings to pop-up again before. I also changed VSCode settings, so if this happens, it will simply disable all null-checks instead of breaking them. So, maybe we'll just disable null analysis entirely on VSCode...
…ter doesn't generate an artifact unlike `verify`
@Jakobeha
Copy link
Contributor Author

Also, I tried to fix null-checks in VSCode. And there's a way to temporarily make them work by changing org.eclipse.jdt.prefs, but it changes back to disable them every time VSCode opens. So they are effectively disabled now.

@Jakobeha Jakobeha merged commit 2cf4651 into main Feb 23, 2024
4 checks passed
@Jakobeha Jakobeha deleted the pmd-ruleset branch February 23, 2024 13:26
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.

1 participant