You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current detekt source discovery omits Android flavor and device-test Kotlin roots. A clean configured gate therefore does not establish that all Android source sets were checked.
A preserved candidate explicitly selects app/src and extends only detekt’s bundled test exclusions to the actual Android flavor-test paths. Its last measured inventory covered 139 Kotlin files and reported five structural findings. No baseline, production exclusion, or threshold increase is proposed.
Resolve the five findings through useful ownership or logic improvements: MobileAuthController function count (16); MobileReadyVideoPlayer complexity (27); TransferItem.statusLabel complexity (16); SignedInMobileRoot readiness condition (5); readyPlayerSubtreeCanBeRemovedAndRecreated length (87).
Preserve exhaustive status handling, single ownership of player/auth state, controller readiness behavior, and the full retained-position lifecycle regression. Do not introduce parameter bags, forwarding helpers, or arbitrary file/class splits merely to satisfy counters.
Enable explicit app/src discovery and document it in AGENTS only once the expanded gate passes.
Acceptance
The detekt task’s actual input inventory includes every intended shared, mobile, TV, and device-test Kotlin root. Record the current count; 139 is historical evidence, not a permanent target.
Temporary negative probes in the six previously omitted roots each fail detekt; remove probes afterward and confirm no exclusions, baseline, or thresholds hide production findings.
The full canonical gate, codegen tests, both debug assemblies, and behavior proof for changed owners pass on the final app/SDK pair.
Run exact-final independent review and publish the repository-required runtime evidence for behavior-sensitive changes.
Until this follow-up lands, detekt retains its existing configured source coverage. The separate source-cleanup PR #122 does not close this gap.
Preserved three-file coverage candidate (reconcile before applying)
verify runs Android Lint (warningsAsErrors, config in app/lint.xml),
-detekt (config in detekt.yml, Compose exemptions only), the local unit
+detekt over all Kotlin sources under app/src/, including flavor and device-test
+source sets (config in detekt.yml, Compose exemptions only), the local unit
tests (app/src/test/, JUnit4 + Robolectric, Compose UI assertions run on
the JVM), and an unsigned minified mobileProductionRelease build that proves
the composite Kotlin SDK against minSdk 26 and R8. :buildSrc:test covers the
diff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 968e409..511ab51 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -118,6 +118,8 @@ androidComponents {
}
detekt {
// Detekt 1.x does not discover flavor sources through AGP's built-in Kotlin support.
Problem
The current detekt source discovery omits Android flavor and device-test Kotlin roots. A clean configured gate therefore does not establish that all Android source sets were checked.
A preserved candidate explicitly selects
app/srcand extends only detekt’s bundled test exclusions to the actual Android flavor-test paths. Its last measured inventory covered 139 Kotlin files and reported five structural findings. No baseline, production exclusion, or threshold increase is proposed.Remaining work
app/srcdiscovery and document it in AGENTS only once the expanded gate passes.Acceptance
Until this follow-up lands, detekt retains its existing configured source coverage. The separate source-cleanup PR #122 does not close this gap.
Preserved three-file coverage candidate (reconcile before applying)
verifyruns Android Lint (warningsAsErrors, config inapp/lint.xml),-detekt (config in
detekt.yml, Compose exemptions only), the local unit+detekt over all Kotlin sources under
app/src/, including flavor and device-test+source sets (config in
detekt.yml, Compose exemptions only), the local unittests (
app/src/test/, JUnit4 + Robolectric, Compose UI assertions run onthe JVM), and an unsigned minified
mobileProductionReleasebuild that provesthe composite Kotlin SDK against minSdk 26 and R8.
:buildSrc:testcovers thediff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 968e409..511ab51 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -118,6 +118,8 @@ androidComponents {
}
detekt {
config.setFrom(rootProject.file("detekt.yml"))
buildUponDefaultConfig = true
}
diff --git a/detekt.yml b/detekt.yml
index 328b81a..2d9db8b 100644
--- a/detekt.yml
+++ b/detekt.yml
@@ -1,10 +1,23 @@
detekt configuration (merged on top of the bundled defaults via
buildUponDefaultConfig). Only deviations from the defaults live here —
mostly Compose idioms the default Kotlin rules reject.
+# Keep bundled test exclusions aligned with Android flavor test source sets.
naming:
FunctionNaming:
ignoreAnnotated: ['Composable']
complexity:
LongMethod:
@@ -12,10 +25,42 @@ complexity:
LongParameterList:
ignoreAnnotated: ['Composable']
TooManyFunctions:
ignoreAnnotatedFunctions: ['Composable', 'Preview']
+exceptions:
+performance:
+potential-bugs:
style:
MagicNumber:
UnusedPrivateMember:
ignoreAnnotated: ['Preview']