hrkfdn / mpdas

MPD AudioScrobbler written in C++ using libcurl
http://50hz.ws/mpdas/
Other
125 stars 22 forks source link

Fixed random timeout issues causing the whole program to hang until r… #33

Closed TheReverend403 closed 8 years ago

TheReverend403 commented 8 years ago

…estart.

Don't ignore curl dude, it has some quite useful error information :)

TheReverend403 commented 8 years ago

Works quite well from my small amount of testing.

Apr 28 22:35:41 serenity mpdas[17940]: (22:35:41) [INFO] New song: Trivium - The Thing That’s Killing Me
Apr 28 22:35:41 serenity mpdas[17940]: (22:35:41) [INFO] Updated "Now Playing" status successfully.
Apr 28 22:36:49 serenity mpdas[17940]: (22:36:49) [INFO] New song: Trivium - Beneath the Sun
Apr 28 22:36:49 serenity mpdas[17940]: (22:36:49) [INFO] Updated "Now Playing" status successfully.
Apr 28 22:46:03 serenity mpdas[17940]: (22:46:03) [INFO] New song: Trivium - Breathe in the Flames
Apr 28 22:46:13 serenity mpdas[17940]: (22:46:13) [ERROR] libcurl: (28)
Apr 28 22:46:13 serenity mpdas[17940]: (22:46:13) [ERROR] Timeout was reached
Apr 28 22:46:13 serenity mpdas[17940]: (22:46:13) [ERROR] Will retry 3 times with a 3 second delay.
Apr 28 22:46:16 serenity mpdas[17940]: (22:46:16) [ERROR] Retry 1/3
Apr 28 22:46:17 serenity mpdas[17940]: (22:46:17) [INFO] Updated "Now Playing" status successfully.
hrkfdn commented 8 years ago

Well well, I certainly didn't mean to ignore what cURL has to say. It's just that back then we didn't know each other very well ;) Also it seems I have never encountered a timeout.

I have merged this locally and am testing this. Will push it upstream soon, I think. Thanks!

TheReverend403 commented 8 years ago

Yeah, a lot of people I spoke to on IRC said the same thing, and the people that were affected by this issue in mpdas also had the exact same problem with mpdscribble, so I'm wondering if it's an account-based issue. The way I always got it to happen was starting a song, leaving it in a paused state for about 15 minutes, then playing a new song.

Anyway, thanks for merging :)