Yuri-YuzuChaN / maimaiDX

基于HoshinoBot V2的舞萌DX查询插件,移植自mai-bot开源项目
MIT License
200 stars 32 forks source link

订阅自己创建的机厅出错 #122

Closed TTsdzb closed 1 year ago

TTsdzb commented 1 year ago
[2023-10-07 21:09:03,058] INFO in message: Self: 3418665443, Message 255465205 from 1370652013@[群:288650149]: '订阅机厅 10000'                       
[2023-10-07 21:09:03,064 maimaiDX排卡] ERROR: <class 'UnboundLocalError'> occured when _ handling message 255465205.                                  
[2023-10-07 21:09:03,060] INFO in msghandler: Message 255465205 triggered _.                                                                          
[2023-10-07 21:09:03,064] ERROR in msghandler: <class 'UnboundLocalError'> occured when _ handling message 255465205.                                 
[2023-10-07 21:09:03,065 maimaiDX排卡] ERROR: local variable 'change' referenced before assignment                                                    
Traceback (most recent call last):                                                                                                                    
  File "/home/pi/HoshinoBot/hoshino/msghandler.py", line 23, in handle_message                                                                        
    await service_func.func(bot, event)                                                                                                               
  File "/home/pi/HoshinoBot/hoshino/modules/maimaiDX/maimai_arcade.py", line 138, in _                                                                
    msg = await subscribe(gid, name, sub)                                                                                                             
  File "/home/pi/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_arcade.py", line 255, in subscribe                                            
    if change:                                                                                                                                        
UnboundLocalError: local variable 'change' referenced before assignment
Yuri-YuzuChaN commented 1 year ago

已修复

TTsdzb commented 1 year ago

还有另一个问题,现在 订阅机厅 会被识别成取消订阅机厅。 可能需要把 maimai_arcade.py 131 行的 '订阅' 改为 '订阅机厅'

Yuri-YuzuChaN commented 1 year ago

确实,已经修复