question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG] tracks array in Player object sometimes have the first song missing

See original GitHub issue

in the event “playlistAdd”, there is a parameter ‘playlist’ which returns a playlist object but, the “queue” array inside the playlist object sometimes don’t include the first song in the playlist (usually there’s about 50% chance to have the first song not included)

To Reproduce

  1. Play a playlist
  2. Use player.on(‘playlistAdd’); Log the playlist object to console and check the tracks array

Expected behavior Tracks array should include all tracks in the playlist

Screenshots image image

Code

client.player.on('playlistAdd', (message, queue, playlist) => {
      console.log('Player emitted playlistAdd Event')
      console.log(playlist)
})

Please complete the following information:

  • Node Version: 14.15.4
  • Discord Player Version: 4.0.9
  • Discord.js Version: 12.5.3

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
skdhgcommented, May 14, 2021

There was an update for ytdl-core so I will have to update this lib as well. I am thinking about resolving your issue with it

0reactions
skdhgcommented, May 14, 2021

update your dep

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error: Track is missing a required key · Issue #97 - GitHub
Hi there - Running into an issue loading up an array of tracks into the player. Here's some information. Checking the docs it...
Read more >
Error thrown after ending the audio track / array of tracks in ...
As a solution what I tried to stop the player once the array of tracks is empty, but it is also. useTrackPlayerEvents([Event.PlaybackQueueEnded] ...
Read more >
MusicKit | Apple Developer Forums
Hi there! I am curious if the MusicPlayer from MusicKit is supported on watchOS. I have not tried it yet, and the documentation...
Read more >
What went wrong? Troubleshooting JavaScript - MDN Web Docs
Go to the tab that you've got number-game-errors. · This is a pretty easy error to track down, and the browser gives you...
Read more >
Bug listing with status RESOLVED with resolution OBSOLETE ...
Bug :1523 - "[IDEA] Offload work by distributing trivial ebuild maintenance ... Bug:43976 - "games-fps/quakeforge: nq-sdl32 crashes (SEG11), sometimes with ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found