Upgrade Kotlin to 2.4.20-Beta2 - #237
Draft
vRallev wants to merge 1 commit into
Draft
Conversation
vRallev
force-pushed
the
ralf/kotlin-2.4.20-beta2
branch
2 times, most recently
from
July 31, 2026 20:44
fd7f0bf to
ecc7c7b
Compare
Move the main build from Kotlin 2.4.10 to 2.4.20-Beta2 and adapt the compiler extension APIs and test goldens for the new compiler. Metro's IR mode no longer invokes App Platform's FIR declaration generators, while downstream Native and Wasm compilations still need FIR package hints to discover contributions. Generate renderer, robot, and scoped binding containers in IR through Metro's contribution API, retain FIR only for cross-module hints, and order App Platform's compiler plugin before Metro's graph transformation. This keeps Metro class generation in IR enabled on every target. Update the affected generated API snapshots and leave the standalone blueprints unchanged.
vRallev
force-pushed
the
ralf/kotlin-2.4.20-beta2
branch
from
July 31, 2026 20:51
ecc7c7b to
65d913b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Issues found
Metro 1.4.0 enables IR class generation with Kotlin 2.4.20-Beta2. App Platform's former FIR declaration generators are therefore not invoked, which removes its generated bindings.
Moving the containers to IR uncovered two additional constraints:
The generated contribution containers are implementation details and no longer appear as source-level declarations or in JVM API snapshots.
Validation
apiCheck, Detekt, Android lint, module-structure checks, generated test runners, and ktfmt passed.sampleandrecipespassed.Upstream references: Kotlin 2.4.20-Beta2, Kotlin EAP configuration, Metro compiler API, Metro issue #2576, and Metro PR #2590.