librespot-golang icon indicating copy to clipboard operation
librespot-golang copied to clipboard

Fix mac mismatch block

Open ViRb3 opened this issue 6 years ago • 4 comments

I'm not sure if this is a proper fix, but it passes along an error that is otherwise ignored, resulting in a block.

ViRb3 avatar Nov 14 '18 20:11 ViRb3

Just reproduced the error, but unfortunately it still blocks:

2018/11/14 18:01:05 received mac doesn't match
Unknown channel!
2018/11/14 18:01:05 received mac doesn't match
Unhandled cmd 0xdc
2018/11/14 18:01:05 received mac doesn't match
Unhandled cmd 0x3c

ViRb3 avatar Nov 14 '18 20:11 ViRb3

I think I narrowed down the issue - it seems that whenever I use the official Spotify on my PC, it 'invalidates' the session used by librespot, which causes the mac mismatch (although with a substantial delay). I tried shutting down all other Spotify clients and running libespot by itself for a full night, no problems.

ViRb3 avatar Dec 24 '18 18:12 ViRb3

This is a good idea, however the error returned should be handled by the parent function and close/restart the connection accordingly. I'm not sure reconnection is properly supported yet, so this is on hold

xplodwild avatar Feb 26 '19 21:02 xplodwild

Indeed, I attempted a reconnect on error, but it seems like the function is not working properly.

ViRb3 avatar Feb 26 '19 23:02 ViRb3