Plex media player not showing state (playing/idle) correctly

Hi

I’m having some random issues with my plex component, it does not always show the correct state.

As you can see in my screenshots below I there are 2 media players, the first one is an external player (outside my network), the second one is internal.

The second one does update with current media_title, the entity_picture etc, so it does have a connection with plex, but the state does not change from “idle” to “playing”. But the top one does… I can’t figure out why this is happening.

The interesting part is that it did show correct state 20 minutes ago, then i tried to create an automation that would trigger my subwooffer to turn on when state is changed to “playing”. For the sake of troubleshooting I have removed that automation and rebooted the HA server, plus i’ve restarted my chrome session to plex and also tried a different mediaplayer (raspberry running rasplex), same issues with that one.

And my automation I tried

- id: Automation 50
  alias: "Movie Theater subwoofer on"
  trigger:
    platform: state
    entity_id: 'media_player.plex_plex_web_chrome'
    to: 'playing'
  condition:
    condition: time
    before: '22:00'
  action:
    service: homeassistant.turn_on
    entity_id: switch.sonoff9

Anyone that has seen similar problems before or could take a qualified guess on what the issue might be?

Yes, the component only tracks if it’s playing or not. If you exit a movie or finish it (e.g. no play/pause command) then it doesn’t get updates. I’ve made a python script for getting track of my plex client that I use to automate scenes.

Awesome! Ill give it a try tomorrow! :slight_smile: