Skip to content
CAI
Software that uses CAICheck a score

vmadalin/android-modular-architecture

59.1

Adequate · 22 September 2026

5.9k

lines of production code

Kotlin

primary language

7

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This is an Android application that allows users to browse and view details of characters, with the ability to save favorites to a local database. The system is built using Kotlin and follows a modular architecture, separating UI components, core data handling, and feature-specific logic into distinct modules. It includes a comprehensive build system with centralized dependency management, automated code quality checks, and extensive unit test coverage for its reusable UI utilities.

Features

Add SingleLiveData for one-time UI events

A new SingleLiveData class is introduced in the commons/ui module to handle one-time UI events, such as navigation or Snackbar messages. This lifecycle-aware observable ensures that only the most recent update is delivered to a single observer, preventing duplicate notifications on configuration changes like screen rotation.

commons/ui/src/main/kotlin/com/vmadalin/commons/ui/livedata · high confidence

Add character list and detail screens

Users can now browse a paginated list of characters and tap an item to view its full details. The list screen displays character cards with loading, error, and empty states, while the detail screen shows character information and allows adding the character to a favorites list.

_features/characters\list · high confidence

Add favorite characters list feature

Users can now view a list of their favorite characters. The feature includes a grid-based list that displays character images and names, with the ability to remove a character by swiping the list item. The list adapts its layout for different screen sizes and orientations, showing one column on small phones, two on tablets and larger phones, and three on wide screens. An empty state is displayed when no favorites are present.

_features/characters\favorites · high confidence

Add local favorite character storage and network state handling

The core module now includes a Room-based database to persist favorite characters, including the \MarvelDatabase\, \CharacterFavorite\ entity, \CharacterFavoriteDao\, and a \CharacterFavoriteRepository\ for data operations. A database migration from version 1 to 2 is provided. Additionally, the update introduces a \NetworkState\ sealed class to represent loading, success, and error states for network requests, alongside a \MarvelRepository\ for handling API calls. The change also establishes a new dependency injection structure using Dagger, with modules for context, database, network, and utilities, all wired through a \CoreComponent\.

core · high confidence

Added build utility functions for local properties and OS detection

New Kotlin utility classes were added to the buildSrc module: BuildUtils, which provides a function to read properties from the local.properties file, and SystemOSUtils, which detects if the build is running on Linux or macOS. These utilities support the Gradle build process by centralizing common build-time logic.

buildSrc/src/main/kotlin/utils · high confidence

App scaffolding and navigation setup

The app module now includes the foundational structure for the application, including the main activity, a navigation graph, and a home fragment. The app supports a dark mode theme with distinct color palettes for light and dark states, and implements dynamic feature module titles for the home, characters list, and favorites sections.

app/src · high confidence

Introduce base UI components for Android development

Added new base classes in the \commons/ui\ module to standardize Android UI initialization and list handling. This includes \BaseFragment\ for simplified fragment setup with data binding and dependency injection, \BaseListAdapter\ and \BasePagedListAdapter\ for RecyclerViews with automatic diffing, \BaseViewHolder\ for data-bound view holders, and a \BaseViewState\ interface to describe view states.

commons/ui/src/main/kotlin/com/vmadalin/commons/ui/base · high confidence

Introduce the Home feature with dark mode toggle and bottom navigation

The Home feature is now fully functional, providing a main screen with a bottom navigation bar to switch between the characters list and favorites. Users can toggle between light and dark themes using a checkbox in the toolbar, which triggers an animated transition between the sun and moon icons. The feature includes its own AndroidManifest module configuration, Dagger 2 dependency injection setup, and ViewModel state management for UI states.

features/home · high confidence

New RecyclerViewItemDecoration utility for consistent item spacing

A new \RecyclerViewItemDecoration\ class has been added to the common UI module, providing a reusable way to apply consistent spacing between items in a RecyclerView. It automatically calculates and applies padding for both GridLayoutManager and LinearLayoutManager, handling edge cases for grid columns and linear scroll directions. This allows developers to easily add uniform spacing to their list views without writing custom decoration logic.

commons/ui/src/main/kotlin/com/vmadalin/commons/ui/recyclerview · high confidence

New UI extension functions and binding adapters

Added a new \commons/ui\ module containing UI helper extensions and data-binding adapters. This includes \ContextExtensions\ for safe string retrieval, \FragmentExtensions\ for generic ViewModel access, \LifecycleOwnerExtensions\ for simplified LiveData observation, and \NavigationExtensions\ to support multiple back stacks in a BottomNavigationView. Additionally, \ViewBindings\ provide convenient visibility toggles, \ImageViewBindings\ handles image loading with placeholders, and \RecyclerViewBindings\ simplify item decoration spacing.

commons/ui/src/main/kotlin/com/vmadalin/commons/ui/extensions · high confidence

New build configuration helpers for buildSrc

Added new Kotlin extension functions in buildSrc to simplify Gradle build configuration. BuildTypeExtensions provide shortcuts for adding string, integer, and boolean fields to the generated BuildConfig class. DependencyHandlerExtensions add convenience methods for common dependency configurations (debugImplementation, implementation, api, kapt, testImplementation, androidTestImplementation) and a helper to batch-apply test dependencies. ProjectExtensions expose a helper to read local properties. RepositoryHandlerExtensions define a method to apply a standard set of Maven repositories (Google, JCenter, Maven Central, and several others).

buildSrc/src/main/kotlin/extensions · high confidence

New buildSrc plugins for code quality, formatting, and dependency management

The build system now includes dedicated Gradle plugin scripts for static analysis and code style enforcement. A new detekt plugin configures the Kotlin static analyzer to produce XML and HTML reports. A dokka plugin generates HTML documentation to the docs directory. Git hooks are automatically installed via a new git-hooks plugin that copies and executes pre-commit scripts. Code style is enforced by a new ktlint plugin that provides tasks for checking and fixing Kotlin code. A spotless plugin standardizes formatting for Markdown, XML, Kotlin, and Gradle files, including header application. Finally, an update-dependencies plugin integrates the Gradle Versions Plugin to check for updates while filtering out pre-release versions.

buildSrc/src/main/kotlin/plugins · high confidence

New reusable progress dialog component

A new 'views' module has been introduced within the commons library, providing a reusable 'ProgressBarDialog' component. This dialog displays a loading spinner and a message, supporting both standard dismissal and an error state. The implementation includes the Kotlin class, the corresponding XML layout with data binding, and associated styling and dimension resources.

commons/views · high confidence

New test utilities library for Android and Kotlin testing

A new \test\_utils\ library has been added to the codebase, providing a suite of helper classes and utilities for testing Android and Kotlin code. This includes a \TestLifecycleOwner\ for managing lifecycle states, \TestLimitDataSource\ and \TestPagedListUtils\ for mocking data sources and paged lists, \TestLiveDataUtils\ for observing LiveData values, and a \CoroutineRule\ for managing coroutine dispatchers in tests. The library also includes test activities and fragments (\TestFragmentActivity\, \TestCompatActivity\, etc.) and a \TestRobolectric\ base class for Robolectric tests.

_libraries/test\utils · high confidence

Project initialization and documentation updates

The repository was initialized with a comprehensive set of documentation files, including a detailed README.md, CHANGELOG.md, and CONTRIBUTING.md. The project also introduced an .editorconfig file to enforce code style and formatting rules across the codebase. Additionally, the .gitignore file was updated to include new build artifacts (\*.aab) and IDE configuration files, while the gradle wrapper scripts (gradlew, gradlew.bat) were added to facilitate building the project.

(repo-wide) · high confidence

Architecture

Centralized build configuration for Android and Kotlin modules

The build system now uses shared Gradle scripts in the buildSrc directory to standardize Android library, dynamic feature, and Kotlin library modules. These scripts enforce consistent compilation, Java 8 compatibility, data binding, product flavors, and dependency injection setups, ensuring all modules follow the same build rules and include common dependencies like Kotlin, Coroutines, Dagger, and Timber.

buildSrc/src/main/kotlin/commons · high confidence

Centralized dependency management via Kotlin DSL

The project has introduced a new buildSrc module that centralizes all external library versions and dependency declarations into typed Kotlin objects (e.g., Dependencies, TestDependencies). This change replaces ad-hoc or scattered dependency definitions with a unified, type-safe approach, making it easier to update library versions and manage test vs. production dependencies.

buildSrc/src/main/kotlin/dependencies · high confidence

Behavioural changes

Add Gradle 6.6.1 wrapper configuration

The project now includes a Gradle wrapper configuration file that pins the Gradle distribution to version 6.6.1, ensuring consistent build environments across development and CI systems.

gradle · medium confidence

Centralized build configuration and dependency management

The project has introduced a centralized build configuration system in the buildSrc module, consolidating Android build settings, dependency versions, module paths, plugin IDs, product flavors, and task groups into dedicated Kotlin objects. This change standardizes how the app is built, with specific versions for libraries like Kotlin (1.4.10), Coroutines (1.3.9), and Coil (0.13.0), while also defining build types for debug and release modes with corresponding minification and coverage settings.

buildSrc/src/main/kotlin · high confidence

Enforce static analysis checks on commit

A new pre-commit hook has been added to the repository that runs static analysis tools (Detekt, Ktlint, Lint, and Spotless) before allowing commits. If any of these checks fail, the commit is blocked and the user is prompted to fix the reported issues. This ensures code style and quality standards are maintained at the time of each commit.

scripts · high confidence

Initial project setup with build and optimization configurations

The app module is initialized with a .gitignore file to exclude build artifacts and a proguard-rules.pro file to preserve specific classes during code shrinking and obfuscation, ensuring that the DataBinderMapperImpl class remains intact for data binding functionality.

app · high confidence

Restored Apache 2.0 license header template for Kotlin files

The project has restored the Apache 2.0 license header template for Kotlin files, ensuring that all new or existing Kotlin files include the proper copyright and licensing information as defined in the \.spotless/copyright.kt\ file.

.spotless · high confidence

Separation of UI and View components into distinct modules

The commons library has been refactored to separate concerns by introducing two new sub-modules: 'ui' and 'views'. Each module is now a distinct build unit with its own configuration files, including a .gitignore to exclude build artifacts and a proguard-rules.pro file to manage code shrinking and obfuscation settings. This structural change allows for more granular dependency management and clearer separation between UI-related code and view-related code within the commons package.

commons · medium confidence

Test coverage

Added tests for UI extensions and LiveData utilities; Added unit tests for RecyclerViewItemDecoration; Added unit tests for common UI base classes and view bindings.

Dependencies

Migrate project build scripts to Kotlin DSL

The project's Gradle build scripts have been migrated from Groovy to Kotlin DSL (build.gradle.kts). This change introduces a centralized build configuration in the buildSrc module, defining versions for key dependencies such as the Android Gradle plugin (4.1.0), Kotlin (1.4.10), and various Gradle plugins including Detekt, Dokka, KtLint, Spotless, and the Gradle versions plugin. The migration also includes updating the settings file to use Kotlin DSL and configuring the app module with data binding, multiple product flavors, and dynamic feature module support.

(dependencies) · medium confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 60 → 59 (-0.9)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 100 (+0.0)
  • Architecture 96 → 94 (-2.2)
  • Maturity 58 → 58 (+0.0)
  • Readiness 50 → 63 (+13.7)
  • Security 97 → 97 (+0.0)
  • Domain Modelling 60 → 47 (-13.0)

Resolved (8)

  • Change coupling clique: BuildDependenciesVersions.kt, TestDependencies.kt, DependencyHandlerExtensions.kt (buildSrc/src/main/kotlin/BuildDependenciesVersions.kt)
  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • No exposed public API
  • Test reliability not included
  • The architecture/Docs set is present but not fully visible in the summary due to clipping; only the first few docs are shown. (docs/index.html)
  • The single README only states purpose and links to badges without describing how to get started or environment setup. (README.md)
  • dormant codebase — no living knowledge left to concentrate

New (7)

  • Change coupling: CharactersListViewModel.kt ↔ CharactersPageDataSource.kt (features/characters_list/src/main/kotlin/com/vmadalin/dynamicfeatures/characterslist/ui/list/CharactersListViewModel.kt)
  • Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
  • Documentation: contradicts the code
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Documentation: written for insiders (docs/index.html)
  • No dependency advisory monitoring

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

vmadalin/android-modular-architecture was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 9fe0723a3bd515337df0837e528968785772e994 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-821afab8930d.