-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[Update Detekt Version] Update Detekt to 1.19.0 #16949
Conversation
You can test the WordPress changes on this Pull Request by downloading an installable build (wordpress-installable-build-pr16949-65cc613.apk), or scanning this QR code: |
You can test the Jetpack changes on this Pull Request by downloading an installable build (jetpack-installable-build-pr16949-65cc613.apk), or scanning this QR code: |
With this update, the configuration for the rules below got updated. Also, one rule, specific to Jetpack Compose, was added: Rules that got updated: - LongParameterList (complexity) - ForbiddenComment (style) Rules that got added: - FunctionNaming (naming) As such, for all the above listed rules, Detekt has started to warn about current violations based on these rule updates. As such those rules need to be updated/added accordingly. This is going to be done in subsequent commits.
With the '1.19.0' Detekt update, the Detekt 'ignoreAnnotated' feature got updated. With that update, the 'javax.inject.Inject' configuration was no longer working and had to be update to its simpler 'Inject' version, which doesn't require the full import naming convention. Also, as part of this update the 'javax.annotation.Generated' or 'Generated' configuration got removed as it is no longer (or was never) necessary. Thus, making this overall configuration much more straightforward.
With the '1.19.0' Detekt update, the Detekt 'values' configuration got updated. With that update, the '['FIXME:', 'STOPSHIP:']' map, although it keeps working as expected, can be update to the list equivalent configuration, which also matches to the 'default-detekt-config.yml' file's configuration. Default Detekt Config: https://github.com/detekt/detekt/blob/main/ detekt-core/src/main/resources/default-detekt-config.yml
This is done in order to ignore the 'Composable' related warning for the 'WordPressTheme' function naming convention. For more info see: https://detekt.dev/docs/introduction/compose
d993076
to
65cc613
Compare
FYI: We can ignore the Buildkite related Instrumented Tests check failing for now. I can merge this to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work @ParaskP7!
Thanks a lot for it 🙇 🥇 💯
Now it should theoretically be possible for me to replace UnusedPrivateMember. allowedNames.regex
with UnusedPrivateMember. ignoreAnnotated[Preview]
❤️ in the pending Compose PR.
Parent: #16892
Closes: #16896
Closes: #16897
This PR:
1.19.0
(from1.17.1
via1.18.1
) (30dff00 + 9bb8c78).PS: I recommend reviewing this PR commit-by-commit.
To test:
detekt
check).Regression Notes
N/A
See
To test
section above.N/A
PR submission checklist:
RELEASE-NOTES.txt
if necessary.