Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Some properties cant be found in detekt config file

I have been using detekt to improve my code quality. I’ve downloaded default config file from the detekt.dev website and these errors comes into play:

Execution failed for task ':app:detekt'.
> Run failed with 12 invalid config properties.
    - Property 'coroutines>SuspendFunSwallowedCancellation' is misspelled or does not exist.
    - Property 'potential-bugs>CastNullableToNonNullableType' is misspelled or does not exist.
    - Property 'potential-bugs>ElseCaseInsteadOfExhaustiveWhen>ignoredSubjectTypes' is misspelled or does not exist.
    - Property 'style>BracesOnIfStatements' is misspelled or does not exist.
    - Property 'style>BracesOnWhenStatements' is misspelled or does not exist.
    - Property 'style>DataClassContainsFunctions>allowOperators' is misspelled or does not exist.
    - Property 'style>DoubleNegativeLambda' is misspelled or does not exist.
    - Property 'style>ForbiddenAnnotation' is misspelled or does not exist.
    - Property 'style>StringShouldBeRawString' is misspelled or does not exist.
    - Property 'style>UnusedParameter' is misspelled or does not exist.
    - Property 'style>UnusedPrivateProperty' is misspelled or does not exist.
    - Property 'style>UseIfInsteadOfWhen>ignoreWhenContainingVariableDeclaration' is misspelled or does not exist.


* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

>Solution :

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Looks like you are using the latest stable version of the Detekt gradle plugin but not the config file.

The properties in your config file are not available yet in the stable release or are already outdated. You can either use the release candidate versions or just remove or comment on them.

I suggest using the latest release candidate, to use it change your plugin version from 1.22.0 to 1.23.0-RC3

I hope it’ll help. Let me know if you have any other questions.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading