Open MarshalX opened 3 years ago
Or you would like to have option to leave the voice chat? ;d
Doesn't the reconnection happen by itself in this case? Why is this code needed?
Why are you sending request to the server? 🤔
@group_call.on_network_status_changed async def _reconnect(_, is_connected: bool): if not is_connected: await group_call.reconnect()
Doesnt it work for you?
There's
Or you would like to have option to leave the voice chat? ;d
I don't think I've found a documentation reffing to when and what happens on network status change.
The reconnect call is there just in case the bot disconnects from the voice chat. I haven't really tested the event honestly and if reconnecting is required.
Doesn't the reconnection happen by itself in this case? Why is this code needed?
The only thing I've noticed is that on_network_status_changed
is triggered as soon as I start playing something and calling reconnect would stop the stream. I just used is_connected
to call reconnect just when and if it's needed.
Doesn't the reconnection happen by itself in this case? Why is this code needed?
The only thing I've noticed is that
on_network_status_changed
is triggered as soon as I start playing something and calling reconnect would stop the stream. I just usedis_connected
to call reconnect just when and if it's needed.
it is triggered when webrtc successfully connected to the media servers. its means that you are connected to voice chat with 99% precision and ready to start playing/recording
Doesn't the reconnection happen by itself in this case? Why is this code needed?
The only thing I've noticed is that
on_network_status_changed
is triggered as soon as I start playing something and calling reconnect would stop the stream. I just usedis_connected
to call reconnect just when and if it's needed.it is triggered when webrtc successfully connected to the media servers. its means that you are connected to voice chat with 99% precision and ready to start playing/recording
Oh, then I got misleaded by it's name. It made me think on something related to the current network status (temporary downtime in the internet connectivity).
Ok. I'm removing it in the next patch since I don't needed. And I'll probably experiment with actual network behaviors like random disconnects and reconnects in the 1.0.0 release 🤔
Unless the library handles that automatically @MarshalX ?
https://github.com/nitanmarcel/tl_radio/blob/45ec4de2e47cab502b669cf6d5d3fa1e734c0830/tl_radio/__main__.py#L178
Why are you sending request to the server? 🤔
Doesnt it work for you?