大佬我想问一下为什么我的websocket库里没有这个函数
AttributeError: module 'websocket' has no attribute 'create_connection'
环境:
windows11
conda python 3.10
websocket 0.2.1
websocket-client 1.4.2
报错信息:
Traceback (most recent call last):
File "C:\Users\bai\Desktop\bilibili-Game\minimize.py", line 4, in
live = Live(544843) # 创建一个Live对象,参数为房间号(roomid)
File "C:\Users\bai\Desktop\bilibili-Game\src\crawler.py", line 131, in init
self.web = LiveMessage(room_id, logger)
File "C:\Users\bai\Desktop\bilibili-Game\src\crawler.py", line 50, in init
self.webs = websocket.create_connection("ws://broadcastlv.chat.bilibili.com:2244/sub")
AttributeError: module 'websocket' has no attribute 'create_connection'
大佬我想问一下为什么我的websocket库里没有这个函数 AttributeError: module 'websocket' has no attribute 'create_connection'
环境: windows11
conda python 3.10
websocket 0.2.1 websocket-client 1.4.2
报错信息: Traceback (most recent call last): File "C:\Users\bai\Desktop\bilibili-Game\minimize.py", line 4, in
live = Live(544843) # 创建一个Live对象,参数为房间号(roomid)
File "C:\Users\bai\Desktop\bilibili-Game\src\crawler.py", line 131, in init
self.web = LiveMessage(room_id, logger)
File "C:\Users\bai\Desktop\bilibili-Game\src\crawler.py", line 50, in init
self.webs = websocket.create_connection("ws://broadcastlv.chat.bilibili.com:2244/sub")
AttributeError: module 'websocket' has no attribute 'create_connection'
尝试了更新websocker还是没有这个函数