Repository navigation
ci: report Java to Kotlin migration progress on pull requests - #850
nickolas-dimitrakas merged 2 commits into
Conversation
Kotlin migration progressNo change to the Java left to convert.
Conversion progress: 0.0% (16,608 of 16,550 baseline Java LOC left to convert). 132 Java files and 36 Kotlin files in scope. |
📦 SDK Size Impact ReportWhat the SDK adds to a minified release APK. Measured against an empty baseline app. Unlike the Rokt kit, android-core ships no Compose and no resources, so there is nothing here that a host app would already provide. mParticle Core SDK
➡️ SDK size impact change is minimal. Raw measurementsTarget branch: {"baseline_dex_bytes": 0, "baseline_download_bytes": 2512, "baseline_install_bytes": 7528, "core_dex_bytes": 218884, "core_download_bytes": 122936, "core_install_bytes": 130189}This PR: {"baseline_dex_bytes": 0, "baseline_download_bytes": 2511, "baseline_install_bytes": 7528, "core_dex_bytes": 218884, "core_download_bytes": 122938, "core_install_bytes": 130188} |
PR SummaryLow Risk Overview Introduces Adds the Kotlin Migration Progress GitHub Actions workflow job to Reviewed by Cursor Bugbot for commit 76c157c. Bugbot is set up for automated code reviews on this repo. Configure here. |
2caa271 to
6ade310
Compare
6ade310 to
e31d469
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit e31d469. Configure here.
01f50f5 to
76c157c
Compare
Binary compatibility
Compares the release AAR against the same artifact at the last version published to Maven Central; R8-renamed classes and members are excluded (see the script docstring). Full japicmp HTML/XML reports are attached as the |
8df919c to
2ca9ca4
Compare
jamesnrokt
left a comment
There was a problem hiding this comment.
Approved and re-ran checks
Adds scripts/kotlin_migration_progress.py, which measures android-core and android-kit-base main sources and reports Java left to convert, the Kotlin share and conversion progress against the baseline, with the public-facade files that stay Java listed in scripts/kotlin-migration-facades.txt. A new Kotlin Migration Progress job posts the numbers on every pull request, measuring the base branch with the head's facade list, and fails when a pull request adds Java to the published modules without the allow-new-java label. The tracker gains the expected numbers at each checkpoint. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The sticky-comment headline and the ratchet step disagreed in two cases: when Java left to convert dropped but total Java still grew, the headline said "converts N lines" with no hint the ratchet would fail the job; and when Java left to convert increased but total Java did not, the headline fell through to "No change," which was simply false, and the ratchet never catches that case either since it only checks total Java. Moved the headline decision out of untested inline bash and into a new render_headline() in kotlin_migration_progress.py (plus a --headline CLI mode), with delta_java checked first so the headline can never contradict the ratchet, and an explicit branch for the previously-silent regression. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2ca9ca4 to
86c46f6
Compare

Summary
Implements the progress report and the "no new Java" ratchet that the migration playbook describes.
scripts/kotlin_migration_progress.pymeasuresandroid-core/src/mainandandroid-kit-base/src/mainand reports, per module and in total: Kotlin LOC, Java LOC, Java that stays by design, Java left to convert, Kotlin share, and conversion progress against the 16,550-line baseline measured at4ee3ba4c. Line counts matchwc -l, so the numbers agree with the tracker.scripts/kotlin-migration-facades.txtlists the 65 Java files that stay Java (the public API customers and kit authors compile against, per the playbook's Scope section, plus everypackage-info.java). Atmainthey total 11,287 LOC.allow-new-javalabel. It is not in the required-check set.scripts/test_kotlin_migration_progress.pycovers the counting, the facade exclusion, the renderers and the clamping; CI runs it first.TRACKER.mdgains the 0.8 row and a "Checkpoints and expected numbers" table with the Java-left, conversion-progress and estimated Kotlin-share values expected at each stack and checkpoint;PLAYBOOK.mdandAGENTS.mdmention the job.Verification
main(4ee3ba4c): Java left 16,550, facade 11,287, Kotlin share 12.0%, conversion progress 0.0%.maincheckout as the base; on this stack it correctly reports the seams added by test: expose explicit test seams for package-private core internals #845 as new Java, which is the expected ratchet signal for that change.Follow-up
The
allow-new-javalabel does not exist yet and needs creating in the repository settings, alongsideapi-change-approvedfrom #843.🤖 Generated with Claude Code