API Changes
- Adds support for
watchosDeviceArm64platform target I1cc04 b/364652024
Bug Fixes
- Added gradle property
androidx.baselineprofile.suppressWarningsto suppress all baseline profile warnings I7c36e b/349646646 - Fixed Baseline Profile Gradle Plugin to use pre-existing
nonMinified…andbenchmark…if created by the app instead of creating wrappers. Ia8934 b/361370179 - Fixed
java.lang.AssertionError: ERRORS (not suppressed): EMULATORwhenautomaticGenerationDuringBuildis enabled on emulators. New argument is used to instead skip the test. If3f51 b/355515798 - Microbenchmark minification - keep subclasses of
org.junit.runner.notification.RunListenerin benchmark library proguard Ic8ed5 b/354264743 - Fix
TraceSectionMetricto Ignore non-terminating slices. Previously these were considered to have -1 duration, e.g. during summation or finding minimum duration. If74b7 - Fixed an issue in
FrameTimingGfxInfoMetricwhere starting the metric would crash if the process wasn't already running. I6e412
New Feature - App Startup Insights
- Initial version of app startup insights can be enabled in Macrobenchmark. 09fae38
To enable in a startup benchmark:
@Test
fun startup {
macrobenchmarkRule.measureRepeated(
…
packageName = "com.example.my.application.id"
metrics = listOf(StartupTimingMetric()),
iterations = 5,
startupMode = StartupMode.COLD,
compilationMode = CompilationMode.None(),
experimentalConfig = ExperimentalConfig(startupInsightsConfig = StartupInsightsConfig(isEnabled = true))
) {
scope.startActivityAndWait(...)
}
}
Then running your startup benchmark will analyze the trace to look for common problems, and print them after metrics to Studio test output in the benchmark tab, e.g.:
StartupBenchmark_startup[startup=COLD,compilationMode=None]
├── Metrics
│ ├── timeToFullDisplayMs min 1,147.2, median 1,208.8, max 1,307.4
│ └── timeToInitialDisplayMs min 1,147.2, median 1,208.8, max 1,307.4
├── App Startup Insights
│ ├── App in debuggable mode (expected: false)
│ │ └── seen in iterations: 0(true) 1(true) 2(true) 3(true) 4(true) 5(true) 6(true) 7(true) 8(true) 9(true)
│ ├── Potential CPU contention with another process (expected: < 100000000ns)
│ │ └── seen in iterations: 4(105022546ns)
│ └── Main Thread - Binder transactions blocked (expected: false)
│ └── seen in iterations: 7(true)
└── Traces
└── Iteration 0 1 2 3 4 5 6 7 8 9
This feature is still a work-in-progress, with improvements to documentation and extensibility to follow, but feedback is welcome.
New Features
- Added gradle property
androidx.baselineprofile.suppressWarningsto suppress all baseline profile warnings. 314153a - Microbench metrics are now displayed in Perfetto traces as counters. 3214854
- Add experimental scripts for disabling jit (requires root / runtime restart), and resetting device perf/test state. These are not currently published as gradle tasks. 7c3732b
- Added benchmark argument to skip tests when running on emulator. When
automaticGenerationDuringbuild is enabled, benchmarks will also trigger baseline profile generation. This will fail, if emulators are used. With the new argumentskipBenchmarksOnEmulatorwe can instead skip the test. 0c2ddcd - Change perf event enable logic to run on API 23+ 2550048
API Changes
- Existing experimental
PerfettoConfigargument toMacrobenchmarkRule.measureRepeated()moved to the newExperimentalConfigobject.
Bug Fixes
- Increase
lockClocks.shretry count 99e9dac - Don't create
nonMinifiedand benchmark build types if existing. Due to a bug, even ifnonMinifiedand benchmark build types existed, they were going to be recreated. e75f0a5 - Ignore non-terminating slices from
TraceSectionMetricresults. a927d20 - Improved emulator check to consider
sdk_prefix. 1587de8 - Treat non-running packages as cleared in
FrameTimingGfxInfoMetric. 35cc79c - Fix
androidx.benchmark.cpuEventCounterproducing corrupt values for non-Instruction events. 06edd59 - Fix
resumeTiming/runWithTimingDisabledto respect metric priority order, and significantly reduce impact of lower priority metric pause/resume on higher priority metric results. For example, if using cpu perf counters viacpuEventCounter.enableinstrumentation argument, timeNs is no longer significantly reduced when pause/resume occur. 5de0968
Bug Fixes
- Fixed the crash when
bindToLifecycleis invoked with a destroyedLifecycleOwner. I6e6d8 - Added visibility animation in
ScreenFlashViewforScreenFlash#applywhich also fixes bugs due to brightness change completing asynchronously after some time. I37cdb - Improved zooming smoothness by overriding zoom settings in the framework on supported devices.
API Changes
- Add
KEY_ROOT_HINT_MEDIA_HOST_VERSIONextra I8796b - Replace
TabContents.Api8Builderclass with@ExperimentalCarApiconstructor inTabContents.Builderclass I26fbe - Add intent action and extras for
CarMediaAppI50782 - Mark messaging APIs as non-experimental I0b070
- Add remote item loading to
SectionedItemTemplate(allows long lists to load without crashing) I0d122 - Add
SectionedItemTemplateto list of supported templates insideTabTemplatein API 8. Idc5d6
Bug Fixes
- Removed manual outlining of access to new platform APIs since this happens automatically via API modeling when using R8 with AGP 7.3 or later (e.g. R8 version 3.3) and for all builds when using AGP 8.1 or later (e.g. D8 version 8.1). Clients who are not using AGP are advised to update to D8 version 8.1 or later. See this article for more details. I9496c b/345472586
Bug Fixes
- Workaround
ArrayIndexOutOfBoundswhen sorting an empty collection. I65245
API Changes
- Adds support for
watchosDeviceArm64platform target. I1cc04 b/364652024
External Contribution
- Prevent setting seekable transition
playTimewhen no transition is running. Thanks Steven Schoen! c2e6e7e6
Bug Fixes
- Fix issue with draggable that was missing down events which caused flings to look slower than normal.
API Changes
TextOverflow.StartEllipsisandTextOverflow.MiddleEllipsisare now available which allows to place ellipsis at the start or middle of the line of the single line text I38913 b/185418980
New Features
- Added
PausableCompositionwhich allows creating a subcomposition that can be paused during composition and and applied asynchronously to the composition. Compiler support is required for pausing which is currently in development. I3394b
Bug Fixes
- Improved performance of accessibility node info and semantics events by removing verbose tracing. I89156 b/362530618
ComposeViewwill no longer crash when passed exceptionally large measurement size da5db b/347036173- Fixed an accessibility screenreader issue where
LiveRegionannouncements on buttons were not made. f66fa7 b/348590026
API Changes
TextOverflow.StartEllipsisandTextOverflow.MiddleEllipsisare now available which allows to place ellipsis at the start or middle of the line of the single line text. I38913 b/185418980
Bug Fixes
- Fix Dalog
dismissOnClickoutside39a3d b/364508685 - Don't clip shadows of dialog content e8e2f b/363027803
- Fix errant behavior when focus search moves between Compose and a View 58377 b/350534714
External Contribution
Bug Fixes
- The
NullSafeMutableLiveDataLint error has improved support for smart casts, avoiding false positives. 85fed6 b/181042665
Dependency Updates
- Lifecycle Runtime Compose now depends on Compose Runtime
1.7.1
Bug Fixes
- From Lifecycle
2.8.6: TheNullSafeMutableLiveDataLint error has improved support for smart casts, avoiding false positives. 85fed6 b/181042665
Dependency Updates
- From Lifecycle
2.8.6: Lifecycle Runtime Compose now depends on Compose Runtime1.7.1 - Lifecycle Runtime now depends on ProfileInstaller
1.4.0
New Features
- Added a new lint rule to ensure the use of the
popBackStackfunction that takes a reified class type when attempting topopBackStackusing type-safe APIs. Ief161 b/358095343
Bug Fixes
- Navigation now requires that the route passed to a
NavGraph'sstartDestinationcontains the values for all required arguments, which includes arguments that are non-nullable and have no default value. I18e74 b/362594265 - Navigation safe args has added support for non-nullable strings such that "null" values will be parsed and stored into the bundle as is. This departs from existing behavior where "null" values are parsed into a null object. This change only applies to non-nullable String types. Nullable strings remain unchanged. I08b4a b/348936238
- A
NavDestinationcan no longer be deeplinked into except through a deep link that was explicitly added to the destination. This also means that you can only navigate to a destination's route with the navigate function overload that takes a string route. This fixes a vulnerability that made it possible to deep link to a potentially protected destination. Ie30e6
Dependency Update
- Navigation Safe Args now depends on Kotlin 1.9.24, rather than Kotlin 2.X, ensuring that developers are not forced to update. a4129a
- Navigation Compose now depends on Compose
1.7.2.
Bug Fixes
- Keyboard not coming up when search is opened for the first time is resolved
- UI fixes related to the font of FindInFile view.
- UI fixes for text selection and drag handle.
Known Issues
- 3D images in PDF documents are not rendered in the viewer.
PdfViewerFragmenthas some performance issues on very large PDF documents (> 250 MB)
New Features
- Updated session opening logic to only open a session inside a
SandboxedSdkViewif the window containing theSandboxedSdkViewis visible. - Updated
SessionObserverlogic to sendonUiContainerChangedwhen the visibility of the window containing theSandboxedSdkViewchanges.
Bug Fixes
- Invoke
onUiContainerChangedwhen the window visibility changes I541cf - Removed manual outlining of access to new platform APIs since this happens automatically via API modeling when using R8 with AGP 7.3 or later (e.g. R8 version 3.3) and for all builds when using AGP 8.1 or later (e.g. D8 version 8.1). Clients who are not using AGP are advised to update to D8 version 8.1 or later. See this article for more details. If6b4c b/345472586
Important changes since 1.3.0
ProfileInstallernow supports capturing/installing profiles on API 35+. Updates toProfileInstallershould no longer be required for platform version updates. 6f9f6fa- Fixes crash when dropping shaders on Android U (API 34), as well as on emulators. I031ca b/274314544
- Fix method flag transcoding in the
V_015Sprofile format. aosp/2906631 aosp/2847740
New Features
- The
room-pagingartifacts have been migrated to be KMP compatible. Ib8756 b/339934824 - The API
invalidationTrackerFlow()has been commonized as a first-party API asInvalidationTracker.createFlow()and is now available for non-Android source sets in KMP projects. (I1fbfa, I8fb29, b/329291639, b/329315924)
API Changes
- All warnings and error messages in Room that use the word
Cursorhave been removed or replaced, asCursoris no longer an accurate general term to use in the KMP version of Room. Id8cd9 b/334087492
Bug Fixes
- Fixed an issue where Room KMP would try to emit code using
UUIDfor non-JVM platforms. b/362994709 - Fixed an issue with the Room Gradle Plugin that would cause an error such as ‘Cannot change attributes of configuration … after it has been locked for mutation’ when being used in a KMP project with Compose Multiplatform. b/343408758
API Changes
- We have added support for the Wear Compose
LazyColumnwith ourScreenScaffold(and added an implementation ofScrollInfoProviderforLazyColumnState). Ib8d29 - We have added
viewportSizetoLazyColumnLayoutInfo. I4187f
Bug Fixes
- We have fixed a bug so that rotary scrolling is now disabled in
ScalingLazyColumnwhen theuserScrollEnabledflag is set tofalse. I490ab b/360295825 - We have made a bug fix to address unexpected vertical padding on curved text. The curved text height now more closely matches the actual space used by the text. Please note that this is likely to break screenshot tests that involve curved text Iaa6ef
- We have reverted a bug fix to
Dialogwhere theonDismissRequestcallback was called whenshowDialogwas set to false, because in some cases this resulted inonDismissRequestbeing called multiple times. I64656
API Changes
- We have added an Indeterminate circular progress indicator. I427a7
- We have added support for progress overflow (>100% progress) for both the
CircularProgressIndicatorand theSegmentedCircularProgressIndicator. When the progress exceeds 1.0, this will be indicated by the newoverflowTrackcolor. Iaaa3d - The round
IconToggleButtonandTextToggleButtonnow support a new shape animation variation, in which different shapes represent checked, unchecked and pressed states. The earlier animated shape variation for the just pressed state continues to be supported. I29f03 - We have removed support for using
EdgeButtonwithColumn, due to the need to specify theEdgeButtonheight explicitly inScreenScaffold. Ie353d - We have added support for the Wear Compose
LazyColumnwith ourScreenScaffold(and added an implementation ofScrollInfoProviderforLazyColumnState). Ib8d29 - We have combined
LocalTextMaxLines,LocalTextAlign,LocalTextOverflowinto a singleLocalTextConfigurationcomposition local to provide a more scalable solution going forwards. I5edbc - We have added arc-large as an additional typescale, reserved for short header text strings at the very top or bottom of the screen, like in Confirmation overlays. I60e3e
- We have added defaults to Button for recommended large and extra large icon sizes and content padding. I84675
Bug Fixes
New Features
- Added support for lazy loading of icons in
UserStyleSettingsandUserStyleOptionswhich is a performance win for loading watch faces. Iaf43d - Added an option for an updated screenshot to be taken whenever the system configuration changes (e.g. if the locale changed) via the new
Watchface.setUpdateScreenshotOnConfigurationChange. By default this setting is off. I765a1
Bug Fixes
- Removed manual outlining of access to new platform APIs since this happens automatically via API modeling when using R8 with AGP 7.3 or later (e.g. R8 version 3.3) and for all builds when using AGP 8.1 or later (e.g. D8 version 8.1). Clients who are not using AGP are advised to update to D8 version 8.1 or later. See this article for more details. Ia60e0 b/345472586
Important changes since 1.11.0
- Add a new API to
WebSettingsCompatto enable/disable BackForwardCache for thisWebSettings. This API is experimental and can be changed in the future. aosp/3111705 - Add a new API to
WebSettingsCompatto control the Speculative Loading behavior for thisWebSettings. Only Prerender is available for now. This API is experimental and can be changed in the future. I13962 - Added a new API to enable Web Authentication in
WebView. Developers can enable/disableWebAuthncalls in aWebViewfor their apps usingWebSettingsCompat#setWebAuthenticationSupport. I8187f
New Features
- Add a utility method to get a
WindowSizeClassfromWindowMetrics. I83f1f - Rename
isAtLeasttocontainsBreakpoint. I85b47 - Add overload to
computeWindowSizeClassusing floats. I3dcb2 b/364677934 b/364677802 b/364680886
Bug Fixes
- Add missing breakpoints to the default
WindowSizeClassbreakpoint set. - Fixed a bug where compact dimensions were not being selected correctly in some cases.
API Changes
- Add the stop reason
STOP_REASON_FOREGROUND_SERVICE_TIMEOUTfor when a foreground worker is stopped due to execution timeout based on the foreground service type. Ibd0af