Bug 419699 - Media still reported as playing when process behind tab is killed
Summary: Media still reported as playing when process behind tab is killed
Status: RESOLVED FIXED
Alias: None
Product: plasma-browser-integration
Classification: Plasma
Component: Chrome (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Kai Uwe Broulik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-04-06 00:44 UTC by Janet Blackquill
Modified: 2020-04-07 17:44 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.19.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Janet Blackquill 2020-04-06 00:44:50 UTC
P-B-I doesn't detect when a tab has been killed, and falsely reports that it's still playing media even when the process backing the tab has been killed.

To test:
1) Play media
2) Kill process behind tab without closing it
Comment 1 Nate Graham 2020-04-06 14:44:40 UTC
Yep, I see this too.
Comment 2 Kai Uwe Broulik 2020-04-07 17:30:54 UTC
Git commit b50818455f89d3b8de059efcc99518c0db4e5353 by Kai Uwe Broulik.
Committed on 07/04/2020 at 17:30.
Pushed by broulik into branch 'master'.

Add better player tab crash handling

There is unfortunately no dedicated signal for this (the process API is for dev builds only), so we can only do:

* When we detect a tab becoming inaudible, check if it's gone now, and signal player gone.
  This will catch the case of a tab crashing while playing
* When sending a command, check if it failed, and signal player gone.
  Instead of doing nothing, the player will disappear.
  Not really better UX right there but at least the user will go "huh?" rather than "why is it not working?"

There's also no error codes on the error object, just sentences...

Differential Revision: https://phabricator.kde.org/D28614

M  +37   -4    extension/extension-mpris.js

https://commits.kde.org/plasma-browser-integration/b50818455f89d3b8de059efcc99518c0db4e5353