gabe565 / CastSponsorSkip

⏭️ Skip YouTube ads and sponsorships on all local Google Cast devices
Apache License 2.0
284 stars 6 forks source link

Stopped working without any apparent errors in debug logs #71

Closed ikornaselur closed 4 months ago

ikornaselur commented 4 months ago

I noticed that skipping sponsor segments stopped working in the past week or two, but the logs are really not showing any activity.

Restarting the players and the container didn't seem to fix the issue.

I'm running CSS in docker with the following docker-compose:

version: "3.9"

services:
  app:
    image: ghcr.io/gabe565/castsponsorskip:latest
    environment:
      TZ: UTC
      CSS_YOUTUBE_API_KEY: ${API_KEY}
      CSS_LOG_LEVEL: debug
    network_mode: host
    restart: unless-stopped

and the logs just show "Requesting update":

time=2024-02-15T19:09:27.556Z level=INFO msg="CastSponsorSkip v0.7.2 (efdb2b5)"
time=2024-02-15T19:09:27.556Z level=INFO msg="Searching for devices..."
time=2024-02-15T19:09:27.762Z level=INFO msg="Connected to cast device." device=Shield
time=2024-02-15T19:09:27.776Z level=DEBUG msg="Ignoring device." device="Speaker" reason="Does not support video"
time=2024-02-15T19:09:27.785Z level=INFO msg="Connected to cast device." device="Kitchen Display"
time=2024-02-15T19:09:28.263Z level=DEBUG msg="Requesting update." device=Shield
time=2024-02-15T19:09:28.287Z level=DEBUG msg="Requesting update." device="Kitchen Display"
time=2024-02-15T19:09:40.290Z level=DEBUG msg="Requesting update." device=Shield

I was initially running CSS in a k3s cluster, where it had been running version 5.0.0 for a long time without issues, but tried updating to 0.7.2 there and then migrating to a separate server with just Docker directly.

Any thoughts on how I could troubleshoot further? For reference, the main player I use is a Nvidia Shield (not the pro)

EvanRowls commented 4 months ago

They're having the same issue with Google Cast. The last youtube app update changed something with the state reporting so when playing a video home assistant can see that youtube is on but thinks it's idle/not playing anything.

At least, I'm assuming you're seeing the issue with Youtube.

https://github.com/home-assistant/core/issues/110142

ikornaselur commented 4 months ago

Yeah, that sounds similar. What I did notice when looking at the logs again last night is that my partner was casting from their iPhone to the Shield, which I think uses the Chromecast in Android TV instead of the YouTube app and it does seem that gets detected by CSS (according to the logs).

But when I play with the main YouTube app, it doesn't get the state, seemingly confirming that it must be something with the YouTube app itself, rather than Chromecast (at least for me). Although I'll have to experiment a little bit more later tonight to see if I can replicate that.

Makeshift commented 4 months ago

Ended up here wondering why mine wasn't working - sounds like this is what's hit it then!

I can confirm that when using go-chromecast standalone (the library CSS is using), it seems to see the YouTube app as idle when it isn't. Same with chromecast-api, so this is most likely the YouTube app not reporting status properly.

EvanDotPro commented 4 months ago

As a very lazy workaround, I've been starting my YT cast session from a computer, then joining from my phone and it works fine after that.

gabe565 commented 4 months ago

Hi! Yeah, I also use an NVIDIA Shield and have been having the same issue. I've tried various workarounds and even tested with older versions, and no dice. I hadn't seen the Home Assistant issue yet (thanks for the link @EvanRowls), but I noticed my HA instance also stopped reporting state. Here's to hoping it's just a bug and not an intended change in functionality 🤞

gabe565 commented 4 months ago

Seems to be working again for me! Must have been a YouTube bug. Is everyone else seeing the same?

Rapti commented 4 months ago

I had this problem as well during the last few weeks. This morning, it suddenly started working again without me doing anything.

EvanRowls commented 4 months ago

Yep, seems to be working again on my end as well.

ikornaselur commented 4 months ago

Can confirm that it's working again here as well! Closing as it seems to be no longer an issue