mirror of
https://github.com/ChenXu233/nonebot_plugin_dialectlist.git
synced 2024-11-30 17:14:45 +08:00
#规范命名
This commit is contained in:
parent
7b0bf0a572
commit
19157be9f2
@ -201,5 +201,6 @@ async def handle_message(
|
|||||||
|
|
||||||
await rankings.send(msg)
|
await rankings.send(msg)
|
||||||
await asyncio.sleep(1) #让图片先发出来
|
await asyncio.sleep(1) #让图片先发出来
|
||||||
await rankings.finish(plugin_config.dialectlist_string_suffix_format.format(timeCost=time.time()-st-1))
|
if plugin_config.dialectlist_string_suffix_format:
|
||||||
|
await rankings.finish(plugin_config.dialectlist_string_suffix_format.format(timecost=time.time()-st-1))
|
||||||
|
|
||||||
|
@ -6,8 +6,8 @@ from pydantic import BaseModel, Extra
|
|||||||
class Config(BaseModel, extra=Extra.ignore):
|
class Config(BaseModel, extra=Extra.ignore):
|
||||||
|
|
||||||
timezone: Optional[str]
|
timezone: Optional[str]
|
||||||
dialectlist_string_format: str = '第{index}名:\n{nickname},{chatDataNum}条消息\n' #消息格式
|
dialectlist_string_format: str = '第{index}名:\n{nickname},{chatdatanum}条消息\n' #消息格式
|
||||||
dialectlist_string_suffix_format: str = '你们的职业是水群吗?————MYX\n计算花费时间:{timeCost}秒' #消息后缀格式
|
dialectlist_string_suffix_format: Optional[str] = '你们的职业是水群吗?————MYX\n计算花费时间:{timecost}秒' #消息后缀格式
|
||||||
dialectlist_get_num:int = 10 #获取人数数量
|
dialectlist_get_num:int = 10 #获取人数数量
|
||||||
dialectlist_visualization:bool = True #是否可视化
|
dialectlist_visualization:bool = True #是否可视化
|
||||||
dialectlist_visualization_type:Literal['饼图','圆环图','柱状图'] = '圆环图' #可视化方案
|
dialectlist_visualization_type:Literal['饼图','圆环图','柱状图'] = '圆环图' #可视化方案
|
||||||
|
@ -183,7 +183,7 @@ async def msg_list2msg(
|
|||||||
for i in range(got_num):
|
for i in range(got_num):
|
||||||
index = i+1
|
index = i+1
|
||||||
nickname,chatdatanum = ranking[i]
|
nickname,chatdatanum = ranking[i]
|
||||||
str_example = plugin_config.dialectlist_string_format.format(index=index,nickname=nickname,chatDataNum=chatdatanum)
|
str_example = plugin_config.dialectlist_string_format.format(index=index,nickname=nickname,chatdatanum=chatdatanum)
|
||||||
out = out + str_example
|
out = out + str_example
|
||||||
|
|
||||||
logger.debug(out)
|
logger.debug(out)
|
||||||
|
Loading…
Reference in New Issue
Block a user