aquelemiguel / parrot

🦜 A hassle-free, highly performant, self-hosted Discord music bot with YouTube and Spotify support. Powered by yt-dlp.
MIT License
136 stars 44 forks source link

Unexpected idle disconnects #181

Closed aquelemiguel closed 2 years ago

aquelemiguel commented 2 years ago

📝 Description

While its logic is correct, #176 introduced a bug where the bot unexpectedly idle disconnects. This is because sometimes skipping a track does not remove it from the queue, but instead keeps it at the top in a paused state. This makes the idle counter not reset and thus may prompt the bot to disconnect earlier than expected if this bug persists on the following tracks.

We should investigate how Songbird handles skipping a track. We've had this issue in the past, which forced us to implement the force_skip_top_track method.

🪜 Reproduction Steps

  1. Trace the counter in idle.rs
  2. Queue multiple songs
  3. Arbitrarily skip and notice that sometimes the counter keeps incrementing

ℹ Environment / Computer Info

📸 Screenshots

No response