jellyfin-chromecast icon indicating copy to clipboard operation
jellyfin-chromecast copied to clipboard

Chromecast client reports being idle regardless of the actual media playback status

Open 4ntsu opened this issue 4 years ago • 9 comments

Describe the bug When casting to a Chromecast device from the Android app or from Google Chrome, regardless of the actual media playback status, when the Chromecast device is queried for its status the result is "Idle (Jellyfin for Google Cast)".

System (please complete the following information):

  • OS: Arch Linux
  • Virtualization: LXC (Proxmox)
  • Clients: Android app or Chrome browser casting to Chromecast (2nd gen)
  • Browser: Google Chrome 84
  • Jellyfin Version: 10.6.3
  • Playback: both transcoding and direct
  • Installed Plugins: AudioDB, Kodi Sync Queue, MusicBrainz, OMDb, Open Subtitles, TVHeadend, TheTVDB
  • Reverse Proxy: nginx
  • Base URL: none
  • Networking: Internal, on the same subnet. Internal DNS points the server's fqdn to the local address of the proxy to avoid hairpin NAT.
  • Storage: NFS

To Reproduce

  1. Open the Jellyfin app on Android or the browser page in Google Chrome.
  2. Click the "cast" icon and select a Chromecast device.
  3. Play a video. Video starts playing on the TV connected to the Chromecast.
  4. Query the Chromecast's status with an application like go-chromecast, for example: go-chromecast --device-name "TV" status
  5. The application returns: Idle (Jellyfin for Google Cast), volume=1.00 muted=false

Expected behavior Upon being queried, the device should return the current playback status (playing, buffering, paused, etc). All other applications tested (Youtube, Disney+, MX Player, Spotify) report their status correctly. Examples:

$ go-chromecast --device-name "TV" status
[Ycz6TXrP-W8] YouTube (PLAYING), title="FINALLY... a Ryzen Mini PC!", artist="", time remaining=515s/929s, volume=1.00, muted=false

$ go-chromecast --device-name "TV" status
Prod MXPlayer (PLAYING), title="some_video.mp4", artist="", time remaining=4s/676s, volume=1.00, muted=false

Logs N/A

Screenshots N/A

Additional context While this does not affect the actual playback of media, it's not the expected behaviour, and prevents go-chromecast from controlling media playback, since the device reports as not playing anything:

$ go-chromecast --device-name "TV" pause
unable to pause cast application: media not yet initialised, there is nothing to pause

4ntsu avatar Aug 24 '20 17:08 4ntsu

Playback Settings -> Nightly/unstable cast player. Save Button. F5. Open cast session. Try again

neopc10 avatar Aug 24 '20 18:08 neopc10

I can't get this setting to take hold in the android app. I might be showing my ignorance of how the jellyfin chromecast process works, but what actually loads the app on the chromecast? Is it the server or the client app?

SteveDinn avatar Aug 24 '20 18:08 SteveDinn

If you're on 1.0.2, force close the app and reopen it. If you're on 2.0.0, casting is broken. There's a sender and a receiver client. The receiver client was non existent before which is why you had the above issue. The nightly receiver client should solve your issue.

Web has an older sender client which technically works and 1.0.2 Android uses a similar one. 2.0.0 is missing that sender client.

neopc10 avatar Aug 24 '20 18:08 neopc10

Thanks @neopc10. Enabling the nightly Chromecast client in the playback settings seems to have worked, but only when casting from the browser (TV client clearly states it's beta, no Jellyfin logo, playback status reports correctly, can be paused by other applications). When Casting from the Android app (version 1.0.2, from PlayStore), it appears to still use the stable Chromecast client (Jellyfin logo with "Ready to cast" message, playback status always idle). I tried restarting the phone, the Chromecast, and fully wiping the app's data and adding the server again, but this behaviour persists.

4ntsu avatar Aug 24 '20 18:08 4ntsu

Did you force close the app?

neopc10 avatar Aug 24 '20 18:08 neopc10

Yes, force closed, rebooted the phone, and wiped the app's data and set it up again (effectively uninstall/reinstall). It invariably launches the stable client.

4ntsu avatar Aug 24 '20 18:08 4ntsu

Yeah, many times, trying to get the screen that says "Jellyfin chromecast beta", but I can only reliably get it from the web site. It got it literally once from the android client, and I cannot figure out how it happened because every other time, no matter what I do, I get the standard app.

On Mon, Aug 24, 2020 at 3:53 PM neopc10 [email protected] wrote:

Did you force close the ap?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/jellyfin/jellyfin-chromecast/issues/57#issuecomment-679303688, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA526U7BYF5HHWQDTEKQ6CLSCKZJPANCNFSM4QJX25YA .

SteveDinn avatar Aug 24 '20 18:08 SteveDinn

I think it's user error. You need to start a new cast session after 1. switching to nightly 2. pressing save 3. force closing the app. Regardless, the 1.0.2 client and its Cast sender are going to be replaced with something completely different.

neopc10 avatar Aug 24 '20 19:08 neopc10

#67

hamburglar2160 avatar Sep 28 '20 15:09 hamburglar2160