Skip to content

Android OS repeatedly sends service start command after restart #1148

@ryanheise

Description

@ryanheise

Platforms exhibiting the bug

  • Android
  • iOS
  • web

Devices exhibiting the bug

Pixel 8

Minimal reproduction project

Minimal reproduction project
audio_service/example/lib/example_playlist.dart

Steps to reproduce

Restart the phone(*) and monitor adb logcat for:

flutter : [IMPORTANT:flutter/shell/platform/android/android_context_vk_impeller.cc(62)] Using the Impeller rendering backend (Vulkan).
System.out: flutterEngine warmed up

I've actually only noticed it when restarting after an OS System update, and it resolves the next time the app is brought into the foreground.

Expected results

I would expect the OS to query audio_service once after restart (for the recent media via onGetRoot).

Actual results

There are repeated service starts.

Screenshots or Video

Screenshots / Video demonstration

[Upload media here]

Logs

Logs
flutter : [IMPORTANT:flutter/shell/platform/android/android_context_vk_impeller.cc(62)] Using the Impeller rendering backend (Vulkan).
System.out: flutterEngine warmed up
flutter : [IMPORTANT:flutter/shell/platform/android/android_context_vk_impeller.cc(62)] Using the Impeller rendering backend (Vulkan).
System.out: flutterEngine warmed up
...

with a few seconds between each start.

Flutter Doctor output

Doctor output
[✓] Flutter (Channel beta, 3.38.0-0.2.pre, on Arch Linux 6.16.1-arch1-1, locale en_US.UTF-8)
[✓] Android toolchain - develop for Android devices (Android SDK version 36.0.0)
[✓] Chrome - develop for the web
[✓] Linux toolchain - develop for Linux desktop
    ! Unable to access driver information using 'eglinfo'.
      It is likely available from your distribution (e.g.: apt install mesa-utils)
[✓] Connected device (2 available)
[✓] Network resources

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions