Repository navigation
ci(replay): Test Session Replay against Compose UI versions from a checked-in file - #6638
Draft
sentry-junior[bot] wants to merge 4 commits into
Draft
sentry-junior[bot] wants to merge 4 commits into
sentry-junior[bot] wants to merge 4 commits into
Conversation
…s from Google Maven Replace the hardcoded composeUi112/composeUi113 build types with a Compose UI matrix workflow. Like the AGP matrix in sentry-android-gradle-plugin, a Kotlin script reads androidx.compose.ui:ui's maven-metadata.xml and picks the latest stable and, when newer, the latest pre-release. Each matrix job runs the replay unit tests with VERSION_COMPOSE_UI forcing that version on the test runtime classpath. The workflow also runs daily, so new Compose releases are tested without a version bump PR. Co-Authored-By: Roman Zavarnitsyn <roman.zavarnitsyn@sentry.io>
📲 Install BuildsAndroid
|
GitHub only notifies the workflow's creator about scheduled runs, which is the bot that pushed it, so a failing daily run would go unnoticed. On a scheduled failure, open an issue, or comment on the open one so repeated failures stay in one place. Co-Authored-By: Roman Zavarnitsyn <roman.zavarnitsyn@sentry.io>
Like the Spring Boot matrix, keep the Compose UI versions in gradle/compose-ui-versions.json instead of looking them up on Google Maven on every run, so the same commit always tests the same versions. Drop the daily schedule and its failure issue, which only made sense with the live lookup. Co-Authored-By: Roman Zavarnitsyn <roman.zavarnitsyn@sentry.io>
…ency matrix plugin Adds io.sentry.dependency-matrix, which reads a versions file in gradle/ and registers <name>Test<version> tasks. Android modules get a build type per version, kept out of check; JVM modules reuse the compiled tests on a versioned runtime classpath. The workflow reads the file with jq inline, like the Spring Boot matrix workflows. Co-Authored-By: roman <roman.zavarnitsyn@sentry.io> Co-Authored-By: Nelson Osacky <nelson.osacky@sentry.io>
This branch has not been deployed
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.
📜 Description
This replaces the hardcoded
composeUiTestVersionsbuild types from #6626 (composeUi112,composeUi113) with a Compose UI matrix that follows the Spring Boot matrix pattern:gradle/compose-ui-versions.jsonlists the Compose UI versions to test: the latest stable and, if it's newer, the latest pre-release.io.sentry.dependency-matrix, reads a versions file fromgradle/and registers a<name>Test<version>task for each version, such ascomposeUiTest1_13_0_rc01. Each task runs the module's unit tests with every dependency in the given group at that version:dependencyMatrix { matrix(name = "composeUi", group = "androidx.compose.ui", versionsFile = "compose-ui-versions.json") }test/check, so the required Build Job only runs the release unit tests.SpringBootMatrixPlugin..github/workflows/compose-ui-matrix.ymlreads the file inline withjqlike the Spring Boot workflows, and runs one job per version on PRs and on pushes tomain.The same commit always tests the same versions. A new Compose release comes in as a change to the JSON file.
💡 Motivation and Context
Session Replay calls Compose internals whose mangled JVM names change between Compose versions. Adding or removing a version is now a one-line change to the JSON file, and other dependencies (Room, okhttp, ...) can reuse the plugin.
Trade-off:
checkstill compiles the matrix variants, becauseverifyMethodParametersreads every variant's AAR. That's the same as onmaintoday.📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
Once this merges, a daily Junior automation bumps
gradle/compose-ui-versions.jsonwhen Google Maven has a newer Compose UI version. It force-pusheschore/update-jetpack-compose-ui-testsand asks @getsentry/team-mobile-android-sdk to review. Dependabot can't update a custom JSON file, andgetsentry/github-workflows/updateronly follows git tags, which AndroidX doesn't publish for Compose.#skip-changelog
via roman.
--
View Session [Sentry]