Skip to content

Conversation

@naveensingh
Copy link
Member

@naveensingh naveensingh commented Nov 5, 2025

Type of change(s)

  • Bug fix
  • Feature / enhancement
  • Infrastructure / tooling (CI, build, deps, tests)
  • Documentation

What changed and why

Added onTaskRemoved() override to ensure internal calls to the player are done on the player thread. This is a quick fix for what appears to be a bug in media3 implementation (internal calls shouldn't assume the player runs on the main thread).

The whole keep player on background thread thing needs to be revisited.

Tests performed

  • Playing, seeking items, closing app by clearing from recents

Closes the following issue(s)

Checklist

  • I read the contribution guidelines.
  • I manually tested my changes on device/emulator (if applicable).
  • I updated the "Unreleased" section in CHANGELOG.md (if applicable).
  • I have self-reviewed my pull request (no typos, formatting errors, etc.).
  • All checks are passing.

@naveensingh naveensingh merged commit cff81f9 into main Nov 5, 2025
9 checks passed
@naveensingh naveensingh deleted the naveensingh/fix-crash-on-task-remove branch November 5, 2025 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Playback stops and app crashes when cleared from recents

2 participants