Bellisario / musicale

Musicale, music with style
https://musicale.tk
MIT License
100 stars 6 forks source link

Error "All APIs are down" 'try again later' #252

Open YAKSL opened 3 weeks ago

YAKSL commented 3 weeks ago

whether the song is in my favorites or in the search results, songs don't seem to play on my end anymore. was there a recent update to youtube APIs that broke streaming? maybe the culprit is simply my location (North Africa) ? it's been at least a week since it's been like this

Capture_Musicale

okay, it might have something to do with this issue on Piped 'Got error: "Sign in to confirm that you're not a bot"' ?

Capture_Piped

i get this error randomly when using the default instance "kavin.rocks (official)" but not on other instances like "kavin.rocks libre (official)" even when i'm signed in (to piped) although it might be reffering to signing in to youtube because it seems like recently they've been enforcing it to view videos.

YAKSL commented 3 weeks ago

now here's the thing i tried using Musicale on my phone and it seemed to work just fine, Firefox on Android and Chromium, Edge on Windows

Bellisario commented 3 weeks ago

I didn't change any API recently... the issue is probably that your IP address with that specific browser (user-agent) was considered "strange" and blocked from Piped's Cloudflare, preventing you from accessing the API.

Once I opened an issue (https://github.com/TeamPiped/Piped/issues/2833) because they were blocking Windows 7/8 devices (as they were considered "old browsers").

For the fact that no other instance was able to act as an alternative from the official one, this could be also because some of them use Cloudflare and others are offline: I put there as many (without CORS) as I could, but I probably need to update them (some might not work anymore at all).


My suggestion is just to wait, downtimes happens also to me sometimes (currently I don't experience it but I see a response slowdown).

A "trick" that could work (if you're not blocked by Cloudflare but Piped is still stuck on the request) is to init a request to Piped (by trying to play the song), wait 2/3 secs, reload and repeat the same multiple times... this sometimes prevents Piped from leaving you stuck on a request and "exploit" another one, giving Piped some time to fetch the data for you.


On Musicale side there's not so much to do as it relies on Piped for everything, anyway some ideas to lower the downtime rates that I could add in the future:

Bellisario commented 3 weeks ago

Update

I've just found that there's an opened issue on Piped itself regarding this problem: https://github.com/TeamPiped/Piped/issues/3658

Seems that Google is doing an a/b test to prevent content scraping, by requiring the user to sign-in to prove of not being a bot...


Anyway, as said before, there's nothing Musicale can do right now to prevent these issues.