Repository navigation
Conversation
Coverage (unit tests)Compared against
Line and branch coverage from unit test reports. History is recorded on the |
Add a workflow that regenerates the library Baseline Profiles on an emulator and opens a pull request when they changed. release-please.yml calls it when the release pull request is created or updated; it skips the emulator run when the library sources did not change since the last profiles, and fails if a module comes out nearly empty. It can also be run by hand. release-please.yml now sets its permissions per job.
kikoso
force-pushed
the
feat/baseline-profiles
branch
from
November 3, 2026 03:32
68d7a25 to
066ee0e
Compare
kikoso
force-pushed
the
ci/regenerate-baseline-profiles
branch
from
November 3, 2026 03:32
6de02f3 to
fdf9e49
Compare
kikoso
marked this pull request as ready for review
November 3, 2026 03:33
Contributor
Coverage (instrumentation tests)
|
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.
Stack
perf: ship Baseline Profiles in maps-compose, maps-compose-utils and maps-compose-widgets(Base →main)feat/baseline-profiles)Summary
Baseline Profiles go stale as the code changes, and nobody will remember to regenerate them by hand. This adds a
Regenerate Baseline Profilesworkflow that runs the generator from #1063 on an emulator and opens a pull request when the profiles changed, so we can merge it before the release pull request.release-please.ymlcalls it (workflow_call) when release-please creates or updates the release pull request. It can also be run by hand (workflow_dispatch, with aforceinput).prs_createdis true every time the release pull request is updated, so after almost every merge. To not burn 20 minutes of emulator each time, the workflow first checks whether any librarysrc/mainchanged since the last commit that touched the profiles, and skips everything else if not.google_apisimage and pinned actions as the demo smoke test, with the key fromACTIONS_API_KEY. It fails right away if the secret is not there..github/scripts/compare_baseline_profiles.pycompares the regenerated profiles with the committed ones. It fails if a module keeps less than half of its rules or comes out empty, which is what happens with a placeholder key or demos that close themselves (it happened to me locally in maps-utils, and the generation still "succeeds"). It also ignores small differences: two runs never record exactly the same methods, so the pull request is only opened when more than 5% of the rules changed.chore/regenerate-baseline-profilesbranch with achore:title so it does not bump the version, and a table with the rules before and after per module plus the classes added and removed. The profiles and test reports are also uploaded as an artifact.release-please.ymlnow sets permissions per job instead of at the workflow level, so the new job only getscontents: read(zizmor flagged the workflow-levelcontents: writeandpull-requests: write).Open questions
SYNCED_GITHUB_TOKEN_REPO, the token release-please already uses, because pull requests opened withGITHUB_TOKENdo not trigger the checks. @dkhawk, is it fine to use it here, or would you prefer another bot token?github-actions[bot]. Ifcla/googledoes not accept it we can switch to the identity release-please commits with.Testing
actionlintpasses on both workflows, andzizmorreports no medium or high findings (only the lowself-repositoryhint for./.github/...).maps-compose/src/main, up to date after a change only inmaps-app.main; I will trigger it by hand withforceafter merging.