polybar / polybar/polybar-scripts

player-mpris-tail: should sort players by recency

Open
#335 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted
Dominant language
Shell
Stars
2.6k
Forks
331
PR merge metrics
No merged PRs in 30d

Description

When I'm playing Spotify and another thing, e.g. Pocket Casts web player, or YouTube, etc., there are multiple players. If I click the player-mpris-tail module to pause say currently-playing Pocket Casts, then Spotify suddenly shows up in the module. Possibly due to the formatted output by the module? But pressing unpause on my media keys again actually plays Pocket Casts again, yet clicking the module would resume Spotify playback instead.

It would be good to sort the players which have been "touched"/interacted with by recency, so that the module doesn't flip between players when interacting with it. The only thing that should change the order is by manually starting or stopping another player externally.

Thanks for your consideration.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the player-mpris-tail module entry point and reproduce the behavior with Spotify plus Pocket Casts or YouTube. Trace how clicking the module and using media keys affect player ordering, then verify that interaction keeps the selected player first while externally started or stopped players can change the order.

Written by the indexing model from the issue text.

Assessment

Tech stack
shell
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.