From edafd7914050e414f9c9599cb6dd02dfcbb71c4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B6=B5=E6=9B=A6?= Date: Sun, 30 Jun 2024 01:07:25 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20#91=20=E4=BF=AE=E5=A4=8D=E4=B8=8B?= =?UTF-8?q?=E8=BD=BD=E6=AD=8C=E6=9B=B2=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- xiaomusic/xiaomusic.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/xiaomusic/xiaomusic.py b/xiaomusic/xiaomusic.py index 8d145c4..b135d67 100644 --- a/xiaomusic/xiaomusic.py +++ b/xiaomusic/xiaomusic.py @@ -311,8 +311,8 @@ class XiaoMusic: async def force_stop_xiaoai(self): ret = await self.mina_service.player_pause(self.device_id) self.log.debug(f"force_stop_xiaoai player_pause ret:{ret}") - #ret = await self.mina_service.player_stop(self.device_id) - #self.log.debug(f"force_stop_xiaoai player_stop ret:{ret}") + # ret = await self.mina_service.player_stop(self.device_id) + # self.log.debug(f"force_stop_xiaoai player_stop ret:{ret}") # 是否在下载中 def is_downloading(self): @@ -703,6 +703,7 @@ class XiaoMusic: self.log.info(f"根据【{name}】找到歌曲【{real_name}】") return real_name self.log.info(f"没找到歌曲【{name}】") + return name # 播放本地歌曲 async def playlocal(self, **kwargs): @@ -759,7 +760,7 @@ class XiaoMusic: await self.do_tts(f"本地不存在歌曲{name}") return await self.download(search_key, name) - self.log.info("正在下载中 %s", search_key + ":" + name) + self.log.info(f"正在下载中 {search_key} {name}") await self.download_proc.wait() # 把文件插入到播放列表里 self.add_download_music(name)