Closed yawntee closed 6 months ago
感谢pr。
但是在测试过程中,发现如果出现断开重连的情况,似乎不会再次调用OnOpen
方法,导致无法发送AuthBody
?
[bili-live][04-22 21:24:44][DEBUG]: Add Option: DANMU_MSG21692711
[bili-live][04-22 21:24:44][DEBUG]: Add Option: SUPER_CHAT_MESSAGE21692711
[bili-live][04-22 21:24:44][DEBUG]: Add Option: SEND_GIFT21692711
[bili-live][04-22 21:24:44][DEBUG]: Add Option: USER_TOAST_MSG21692711
[bili-live][04-22 21:24:44][DEBUG]: Add Option: INTERACT_WORD21692711
[bili-live][04-22 21:24:44][DEBUG]: Add Option: HEARTBEAT_REPLY21692711
[bili-live][04-22 21:24:44][DEBUG]: try to get live room info: 21692711
[bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket: wss://zj-cn-live-comet.chat.bilibili.com:2245/sub
[bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket success
[bili-live][04-22 21:24:44][INFO]: connected to blive success: 21692711
[bili-live][04-22 21:24:44][DEBUG]: start blive success: 21692711
[bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket success
[bili-live][04-22 21:24:44][DEBUG]: send auth msg to blive success
[bili-live][04-22 21:24:44][INFO]: disconnected from blive: 21692711
[bili-live][04-22 21:24:46][DEBUG]: try to get live room info: 21692711
[bili-live][04-22 21:24:46][DEBUG]: connect to blive websocket: wss://zj-cn-live-comet.chat.bilibili.com:2245/sub
[bili-live][04-22 21:24:46][DEBUG]: connect to blive websocket success
[bili-live][04-22 21:24:46][INFO]: connected to blive success: 21692711
[bili-live][04-22 21:25:14][DEBUG]: send heart beat to blive...
[bili-live][04-22 21:25:44][DEBUG]: send heart beat to blive...
模拟了一个cookie
不合法的情况,在发送认证包后会被断开,在再次连接时不会发送认证包
感谢pr。
但是在测试过程中,发现如果出现断开重连的情况,似乎不会再次调用
OnOpen
方法,导致无法发送AuthBody
?[bili-live][04-22 21:24:44][DEBUG]: Add Option: DANMU_MSG21692711 [bili-live][04-22 21:24:44][DEBUG]: Add Option: SUPER_CHAT_MESSAGE21692711 [bili-live][04-22 21:24:44][DEBUG]: Add Option: SEND_GIFT21692711 [bili-live][04-22 21:24:44][DEBUG]: Add Option: USER_TOAST_MSG21692711 [bili-live][04-22 21:24:44][DEBUG]: Add Option: INTERACT_WORD21692711 [bili-live][04-22 21:24:44][DEBUG]: Add Option: HEARTBEAT_REPLY21692711 [bili-live][04-22 21:24:44][DEBUG]: try to get live room info: 21692711 [bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket: wss://zj-cn-live-comet.chat.bilibili.com:2245/sub [bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket success [bili-live][04-22 21:24:44][INFO]: connected to blive success: 21692711 [bili-live][04-22 21:24:44][DEBUG]: start blive success: 21692711 [bili-live][04-22 21:24:44][DEBUG]: connect to blive websocket success [bili-live][04-22 21:24:44][DEBUG]: send auth msg to blive success [bili-live][04-22 21:24:44][INFO]: disconnected from blive: 21692711 [bili-live][04-22 21:24:46][DEBUG]: try to get live room info: 21692711 [bili-live][04-22 21:24:46][DEBUG]: connect to blive websocket: wss://zj-cn-live-comet.chat.bilibili.com:2245/sub [bili-live][04-22 21:24:46][DEBUG]: connect to blive websocket success [bili-live][04-22 21:24:46][INFO]: connected to blive success: 21692711 [bili-live][04-22 21:25:14][DEBUG]: send heart beat to blive... [bili-live][04-22 21:25:44][DEBUG]: send heart beat to blive...
模拟了一个
cookie
不合法的情况,在发送认证包后会被断开,在再次连接时不会发送认证包
抱歉,忘记启动websocket消息循环了,现在我测试重连是正常的