tehkillerbee / mopidy-tidal

Tidal Backend plugin for Mopidy
Apache License 2.0
93 stars 28 forks source link

Unauthorized? #171

Closed fmarzocca closed 5 months ago

fmarzocca commented 5 months ago

This morning I had this error, and can't load any Tidal playlist anymore...

2024-05-10 08:30:00,082 INFO [641:TidalBackend-3 (_actor_loop)] tidalapi.session: Loading session from /var/lib/mopidy/tidal/tidal-oauth.json...
2024-05-10 08:30:00,797 WARNING [641:TidalBackend-3 (_actor_loop)] tidalapi.request: HTTP error on 401
2024-05-10 08:30:00,798 INFO [641:TidalBackend-3 (_actor_loop)] tidalapi.request: Got exception 401 Client Error: Unauthorized for url: https://
api.tidal.com/v1/sessions?limit=1000

What does it mean?

tehkillerbee commented 5 months ago

It just looks like your authentication has failed.

Have you tried reauthentication with PKCE auth to see if it works?

fmarzocca commented 5 months ago

Until yesterday it worked. Should I have to delete the auth json file again? I am using oauth

fmarzocca commented 5 months ago

Yes. After deleting the oauth.json file it worked back again.

fmarzocca commented 5 months ago

Any chance to avoid this random disconnects?

tehkillerbee commented 5 months ago

I have never experienced this problem myself, sorry so I doubt it's a tidalapi issue. But perhaps tidal has changed their way that irregular behaviour is detected, resulting in your account requiring reauth.

One fix could be to trigger reauth automatically, when this issue occurs. But not something I see necessary to add, unless this issue becomes more frequent.