Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lavalink.py generates errors when it receives messages from the Lavalink server #153

Open
maxsspeaker opened this issue Dec 30, 2024 · 4 comments

Comments

@maxsspeaker
Copy link

maxsspeaker commented Dec 30, 2024

Summary

Over time, errors begin to appear in the logs, some people complain that their player is broken

Lavalink & System Version

Arch Linux ARM last verison on 31.12.2024
python 3.12
Lavalink.py 5.9.0
Lavalink 4.0.8

  • youtube-source 1.11.2

Reproduction

at a random moment an error begins to appear in the logs related to receiving data from the Lavalink server, although now it has turned into spam

Expected Results

The error should not occur, or some explanation for this situation

Actual Results

[Node:maxsspeaker-node] Unexpected error occurred whilst processing websocket message
Traceback (most recent call last):
File "/home/maxsspeaker/.local/lib/python3.12/site-packages/lavalink/transport.py", line 230, in _handle_message_safe
await self._handle_message(msg.json())
File "/home/maxsspeaker/.local/lib/python3.12/site-packages/lavalink/transport.py", line 274, in _handle_message
await self._handle_event(data)
File "/home/maxsspeaker/.local/lib/python3.12/site-packages/lavalink/transport.py", line 303, in _handle_event
assert player.current is not None
^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

Checklist

  • [+] Have you checked that there aren't other open Bug Reports for the same problem?
  • [+] Have you checked that your Lavalink password isn't visible?
  • [+] Have you given a traceback if possible?

изображение

@devoxin
Copy link
Owner

devoxin commented Dec 30, 2024

Are you calling player.skip() multiple times in a row?

@maxsspeaker
Copy link
Author

maxsspeaker commented Dec 31, 2024

no, I use my own code, where next is used instead of skip, in the code, it is implemented as "player.stop" and then "player.play(AudioTreak)", but such errors begin to occur when the player is running for a very long time without interruption

Edit:
Sorry for the confusion, I'm on my computer now, I'm just executing the command "player.play(AudioTreak)" without using player.stop

@devoxin
Copy link
Owner

devoxin commented Dec 31, 2024

There is a known issue where many calls to player.play() in quick succession can cause this issue but I've not heard of this issue occurring under any other conditions

@maxsspeaker
Copy link
Author

Any ideas on how I can fix this problem? Since at the moment, the bot plays music correctly, but these errors appear over time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants