Overview
Correctness | |
1 | warning UnusedAttribute: Attribute unused on older versions |
1 | warning RedundantLabel: Redundant label on activity |
8 | warning GradleDependency: Obsolete Gradle Dependency |
Security | |
3 | warning TrustAllX509TrustManager: Insecure TLS/SSL trust manager |
Performance | |
1 | warning
Recycle: Missing recycle() calls |
2 | warning ObsoleteSdkInt: Obsolete SDK_INT Version Check |
7 | warning UnusedResources: Unused resources |
Productivity | |
1 | warning KtxExtensionAvailable: KTX Extension Available |
Included Additional Checks (63) | |
Disabled Checks (42) |
Attribute unused on older versions
../../src/main/AndroidManifest.xml:35:
32 <!-- If your app targets Android 13 (API level 33) 33 or higher, you must declare the NEARBY_WIFI_DEVICES permission. --> 34 <uses-permission android:name="android.permission.NEARBY_WIFI_DEVICES" 35 android:usesPermissionFlags="neverForLocation" /> 36 <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" 37 android:maxSdkVersion="32" /> 38 <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"
UnusedAttribute
Correctness
Warning
Priority 6/10
Redundant label on activity
../../src/main/AndroidManifest.xml:72:
69 <activity 70 android:name=".VNetTestActivity" 71 android:exported="true" 72 android:label="@string/app_name" 73 android:theme="@style/Theme.HttpOverBluetooth"> 74 <intent-filter> 75 <action android:name="android.intent.action.MAIN" />
RedundantLabel
Correctness
Warning
Priority 5/10
Obsolete Gradle Dependency
../../build.gradle:67:
64 implementation "ch.acra:acra-dialog:$version_acra" 65 66 implementation "com.github.yuriy-budiyev:code-scanner:$version_code_scanner" 67 implementation "androidx.navigation:navigation-compose:$version_navigation" 68 implementation "org.kodein.di:kodein-di-framework-compose:$version_kodein_di" 69 implementation "org.kodein.di:kodein-di-framework-android-x:$version_kodein_di" 70 implementation "androidx.datastore:datastore-preferences:$version_datastore"../../build.gradle:71:
68 implementation "org.kodein.di:kodein-di-framework-compose:$version_kodein_di" 69 implementation "org.kodein.di:kodein-di-framework-android-x:$version_kodein_di" 70 implementation "androidx.datastore:datastore-preferences:$version_datastore" 71 implementation "com.squareup.okhttp3:okhttp:$version_okhttp" 72 implementation "org.nanohttpd:nanohttpd:$version_nanohttpd" 73 implementation "com.github.seancfoley:ipaddress:$version_ip_address"../../build.gradle:79:
76 implementation "com.journeyapps:zxing-android-embedded:$version_zxing_embedded" 77 78 79 implementation "androidx.core:core:$version_androidx_core" 80 implementation "androidx.core:core-ktx:$version_androidx_core" 81 implementation "androidx.lifecycle:lifecycle-runtime-ktx:$version_android_lifecycle" 82 implementation "androidx.activity:activity-compose:$version_android_activity"../../build.gradle:80:
77 78 79 implementation "androidx.core:core:$version_androidx_core" 80 implementation "androidx.core:core-ktx:$version_androidx_core" 81 implementation "androidx.lifecycle:lifecycle-runtime-ktx:$version_android_lifecycle" 82 implementation "androidx.activity:activity-compose:$version_android_activity" 83 implementation platform("androidx.compose:compose-bom:$version_compose_bom")../../build.gradle:81:
78 79 implementation "androidx.core:core:$version_androidx_core" 80 implementation "androidx.core:core-ktx:$version_androidx_core" 81 implementation "androidx.lifecycle:lifecycle-runtime-ktx:$version_android_lifecycle" 82 implementation "androidx.activity:activity-compose:$version_android_activity" 83 implementation platform("androidx.compose:compose-bom:$version_compose_bom") 84 implementation 'androidx.compose.ui:ui'../../build.gradle:82:
79 implementation "androidx.core:core:$version_androidx_core" 80 implementation "androidx.core:core-ktx:$version_androidx_core" 81 implementation "androidx.lifecycle:lifecycle-runtime-ktx:$version_android_lifecycle" 82 implementation "androidx.activity:activity-compose:$version_android_activity" 83 implementation platform("androidx.compose:compose-bom:$version_compose_bom") 84 implementation 'androidx.compose.ui:ui' 85 implementation 'androidx.compose.ui:ui-graphics'../../build.gradle:105:
102 androidTestImplementation "androidx.test:rules:$version_androidx_test_rules" 103 androidTestImplementation project(":test-shared") 104 105 androidTestImplementation "org.mockito:mockito-android:$version_android_mockito" 106 androidTestImplementation "org.mockito.kotlin:mockito-kotlin:$version_kotlin_mockito" 107 androidTestImplementation "app.cash.turbine:turbine:$version_turbine"../../build.gradle:106:
103 androidTestImplementation project(":test-shared") 104 105 androidTestImplementation "org.mockito:mockito-android:$version_android_mockito" 106 androidTestImplementation "org.mockito.kotlin:mockito-kotlin:$version_kotlin_mockito" 107 androidTestImplementation "app.cash.turbine:turbine:$version_turbine" 108 109 androidTestUtil "androidx.test:orchestrator:$version_androidx_orchestrator"
GradleDependency
Correctness
Warning
Priority 4/10
Insecure TLS/SSL trust manager
../../../../../../.gradle/caches/modules-2/files-2.1/org.bouncycastle/bcpkix-jdk18on/1.75/5adfef8a71a0933454739264b56283cc73dd2383/bcpkix-jdk18on-1.75.jar:
../../../../../../.gradle/caches/modules-2/files-2.1/com.athaydes.rawhttp/rawhttp-core/2.5.2/cbd0e0de9c307aeb5b1931221e70599c064fa20a/rawhttp-core-2.5.2.jar:
../../../../../../.gradle/caches/modules-2/files-2.1/com.athaydes.rawhttp/rawhttp-core/2.5.2/cbd0e0de9c307aeb5b1931221e70599c064fa20a/rawhttp-core-2.5.2.jar:
../../../../../../.gradle/caches/modules-2/files-2.1/com.athaydes.rawhttp/rawhttp-core/2.5.2/cbd0e0de9c307aeb5b1931221e70599c064fa20a/rawhttp-core-2.5.2.jar:
../../../../../../.gradle/caches/modules-2/files-2.1/com.athaydes.rawhttp/rawhttp-core/2.5.2/cbd0e0de9c307aeb5b1931221e70599c064fa20a/rawhttp-core-2.5.2.jar:
TrustAllX509TrustManager
Security
Warning
Priority 6/10
Missing recycle() calls
../../src/main/java/com/ustadmobile/meshrabiya/testapp/server/TestAppServer.kt:132:
129 it.id == xferId 130 } 131 132 val contentIn = appContext.contentResolver.openInputStream(outgoingXfer.uri)?.let { 133 InputStreamCounter(it.buffered()) 134 }
Recycle
Performance
Warning
Priority 7/10
Obsolete SDK_INT Version Check
ObsoleteSdkInt
Performance
Warning
Priority 6/10
Unused resources
../../src/main/res/values/colors.xml:3:
1 <?xml version="1.0" encoding="utf-8"?> 2 <resources> 3 <color name="purple_200">#FFBB86FC</color> 4 <color name="purple_500">#FF6200EE</color> 5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color>../../src/main/res/values/colors.xml:4:
1 <?xml version="1.0" encoding="utf-8"?> 2 <resources> 3 <color name="purple_200">#FFBB86FC</color> 4 <color name="purple_500">#FF6200EE</color> 5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color>../../src/main/res/values/colors.xml:5:
2 <resources> 3 <color name="purple_200">#FFBB86FC</color> 4 <color name="purple_500">#FF6200EE</color> 5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color> 8 <color name="black">#FF000000</color>../../src/main/res/values/colors.xml:6:
3 <color name="purple_200">#FFBB86FC</color> 4 <color name="purple_500">#FF6200EE</color> 5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color> 8 <color name="black">#FF000000</color> 9 <color name="white">#FFFFFFFF</color>../../src/main/res/values/colors.xml:7:
4 <color name="purple_500">#FF6200EE</color> 5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color> 8 <color name="black">#FF000000</color> 9 <color name="white">#FFFFFFFF</color> 10 </resources>../../src/main/res/values/colors.xml:8:
5 <color name="purple_700">#FF3700B3</color> 6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color> 8 <color name="black">#FF000000</color> 9 <color name="white">#FFFFFFFF</color> 10 </resources>../../src/main/res/values/colors.xml:9:
6 <color name="teal_200">#FF03DAC5</color> 7 <color name="teal_700">#FF018786</color> 8 <color name="black">#FF000000</color> 9 <color name="white">#FFFFFFFF</color> 10 </resources>
UnusedResources
Performance
Warning
Priority 3/10
KTX Extension Available
../../build.gradle:79:
76 implementation "com.journeyapps:zxing-android-embedded:$version_zxing_embedded" 77 78 79 implementation "androidx.core:core:$version_androidx_core" 80 implementation "androidx.core:core-ktx:$version_androidx_core" 81 implementation "androidx.lifecycle:lifecycle-runtime-ktx:$version_android_lifecycle" 82 implementation "androidx.activity:activity-compose:$version_android_activity"
KtxExtensionAvailable
Productivity
Information
Priority 4/10
Included Additional Checks
This card lists all the extra checks run by lint, provided from libraries,
build configuration and extra flags. This is included to help you verify
whether a particular check is included in analysis when configuring builds.
(Note that the list does not include the hundreds of built-in checks into lint,
only additional ones.)
Disabled Checks
One or more issues were not run by lint, either
because the check is not enabled by default, or because
it was disabled with a command line flag or via one or
more
lint.xml
configuration files in the project directories.
Suppressing Warnings and Errors
Lint errors can be suppressed in a variety of ways:
1. With a
2. With a
3. With a //noinspection comment in the source code
4. With ignore flags specified in the
5. With a
6. With a
7. With the --ignore flag passed to lint.
To suppress a lint warning with an annotation, add a
To suppress a lint warning with a comment, add a
To suppress a lint warning in an XML file, add a
To suppress a lint warning in a
Here we specify a comma separated list of issue id's after the disable command. You can also use
To suppress lint warnings with a configuration XML file, create a file named
The format of the
To suppress lint checks from the command line, pass the --ignore flag with a comma separated list of ids to be suppressed, such as:
For more information, see https://developer.android.com/studio/write/lint.html#config
1. With a
@SuppressLint
annotation in the Java code2. With a
tools:ignore
attribute in the XML file3. With a //noinspection comment in the source code
4. With ignore flags specified in the
build.gradle
file, as explained below5. With a
lint.xml
configuration file in the project6. With a
lint.xml
configuration file passed to lint via the --config flag7. With the --ignore flag passed to lint.
To suppress a lint warning with an annotation, add a
@SuppressLint("id")
annotation on the class, method or variable declaration closest to the warning instance you want to disable. The id can be one or more issue id's, such as "UnusedResources"
or {"UnusedResources","UnusedIds"}
, or it can be "all"
to suppress all lint warnings in the given scope.To suppress a lint warning with a comment, add a
//noinspection id
comment on the line before the statement with the error.To suppress a lint warning in an XML file, add a
tools:ignore="id"
attribute on the element containing the error, or one of its surrounding elements. You also need to define the namespace for the tools prefix on the root element in your document, next to the xmlns:android
declaration:xmlns:tools="http://schemas.android.com/tools"
To suppress a lint warning in a
build.gradle
file, add a section like this:android { lintOptions { disable 'TypographyFractions','TypographyQuotes' } }
Here we specify a comma separated list of issue id's after the disable command. You can also use
warning
or error
instead of disable
to change the severity of issues.To suppress lint warnings with a configuration XML file, create a file named
lint.xml
and place it at the root directory of the module in which it applies.The format of the
lint.xml
file is something like the following:<?xml version="1.0" encoding="UTF-8"?> <lint> <!-- Ignore everything in the test source set --> <issue id="all"> <ignore path="\*/test/\*" /> </issue> <!-- Disable this given check in this project --> <issue id="IconMissingDensityFolder" severity="ignore" /> <!-- Ignore the ObsoleteLayoutParam issue in the given files --> <issue id="ObsoleteLayoutParam"> <ignore path="res/layout/activation.xml" /> <ignore path="res/layout-xlarge/activation.xml" /> <ignore regexp="(foo|bar)\.java" /> </issue> <!-- Ignore the UselessLeaf issue in the given file --> <issue id="UselessLeaf"> <ignore path="res/layout/main.xml" /> </issue> <!-- Change the severity of hardcoded strings to "error" --> <issue id="HardcodedText" severity="error" /> </lint>
To suppress lint checks from the command line, pass the --ignore flag with a comma separated list of ids to be suppressed, such as:
$ lint --ignore UnusedResources,UselessLeaf /my/project/path
For more information, see https://developer.android.com/studio/write/lint.html#config