🐱👤拉格兰有点问题

This commit is contained in:
EillesWan 2024-08-11 11:30:41 +08:00
parent 63a25def66
commit fe95e689bc
2 changed files with 14 additions and 7 deletions

View File

@ -238,7 +238,7 @@ async def _():
except: except:
pass pass
query_convert_points(qqid,"music",0,False) query_convert_points(qqid, "music", 0, False)
filesaves[qqid]["totalSize"] -= filesaves[qqid][name]["size"] filesaves[qqid]["totalSize"] -= filesaves[qqid][name]["size"]
nonebot.logger.info( nonebot.logger.info(
"\t删除{}".format(name), "\t删除{}".format(name),
@ -971,23 +971,29 @@ async def _(
Musicreater.plugin.archive.compress_zipfile( Musicreater.plugin.archive.compress_zipfile(
usr_temp_path, usr_temp_path,
fp := str( fp := str(
temporary_dir (
/ ( temporary_dir
fn := "msctr[{}]-{}.zip".format( / (
utime_hanzify(zhDateTime.DateTime.now().to_lunar()), usr_id fn := "msctr[{}]-{}.zip".format(
utime_hanzify(zhDateTime.DateTime.now().to_lunar()), usr_id
)
) )
) ).resolve()
), ),
) )
shutil.rmtree(usr_temp_path) shutil.rmtree(usr_temp_path)
# await linglun_convert.send(UniMessage.file(name=fn, path=fp))
if isinstance(event, GroupMessageEvent) or isinstance( if isinstance(event, GroupMessageEvent) or isinstance(
event, GroupUploadNoticeEvent event, GroupUploadNoticeEvent
): ):
await bot.call_api( res_id = await bot.call_api(
"upload_group_file", group_id=event.group_id, name=fn, file=fp "upload_group_file", group_id=event.group_id, name=fn, file=fp
) )
await linglun_convert.send(UniMessage.text("文件已上传群文件,请在群文件查看。"))
# await linglun_convert.send(UniMessage.file(res_id,path=fp,name=fn))
else: else:
await bot.call_api( await bot.call_api(
"upload_private_file", user_id=event.user_id, name=fn, file=fp "upload_private_file", user_id=event.user_id, name=fn, file=fp

View File

@ -413,6 +413,7 @@ async def _(
await bot.call_api( await bot.call_api(
"upload_group_file", group_id=event.group_id, name=fn, file=fp "upload_group_file", group_id=event.group_id, name=fn, file=fp
) )
await mspv_sync.send(UniMessage.text("文件已上传群文件,请在群文件查看。"))
else: else:
await bot.call_api( await bot.call_api(
"upload_private_file", user_id=event.user_id, name=fn, file=fp "upload_private_file", user_id=event.user_id, name=fn, file=fp