diff --git a/plugins/brushflow/__init__.py b/plugins/brushflow/__init__.py index 74a1c7a..ed5e43a 100644 --- a/plugins/brushflow/__init__.py +++ b/plugins/brushflow/__init__.py @@ -3493,7 +3493,7 @@ class BrushFlow(_PluginBase): 记录错误日志并发送系统通知 """ logger.error(message) - self.systemmessage.put(message) + self.systemmessage.put(message, title="站点刷流") def __send_delete_message(self, site_name: str, torrent_title: str, torrent_desc: str, reason: str, title: str = "【刷流任务种子删除】"): diff --git a/plugins/categoryeditor/__init__.py b/plugins/categoryeditor/__init__.py index f533c2d..a7f2cfe 100644 --- a/plugins/categoryeditor/__init__.py +++ b/plugins/categoryeditor/__init__.py @@ -40,11 +40,11 @@ class CategoryEditor(_PluginBase): if self._enabled: self.user_yaml.write_text(self._content, encoding="utf-8") if not settings.LIBRARY_CATEGORY: - self.systemmessage.put("二级分类未开启,策略已保存但未生效!") + self.systemmessage.put("二级分类未开启,策略已保存但未生效!", title="二级分类策略") return # 立即生效 CategoryHelper().init() - self.systemmessage.put("二级分类策略已更新!") + self.systemmessage.put("二级分类策略已更新!", title="二级分类策略") def get_state(self) -> bool: return self._enabled diff --git a/plugins/cloudflarespeedtest/__init__.py b/plugins/cloudflarespeedtest/__init__.py index 62ff836..df1e7f2 100644 --- a/plugins/cloudflarespeedtest/__init__.py +++ b/plugins/cloudflarespeedtest/__init__.py @@ -97,7 +97,7 @@ class CloudflareSpeedTest(_PluginBase): self._scheduler.start() except Exception as err: logger.error(f"Cloudflare CDN优选服务出错:{str(err)}") - self.systemmessage.put(f"Cloudflare CDN优选服务出错:{str(err)}") + self.systemmessage.put(f"Cloudflare CDN优选服务出错:{str(err)}", title="Cloudflare IP优选") return @eventmanager.register(EventType.PluginAction) @@ -803,7 +803,7 @@ class CloudflareSpeedTest(_PluginBase): err_hosts.append(host + "\n") logger.error(f"[HOST] 格式转换错误:{str(err)}") # 推送实时消息 - self.systemmessage.put(f"[HOST] 格式转换错误:{str(err)}") + self.systemmessage.put(f"[HOST] 格式转换错误:{str(err)}", title="Cloudflare IP优选") # 写入系统hosts if new_entrys: @@ -818,7 +818,7 @@ class CloudflareSpeedTest(_PluginBase): err_flag = True logger.error(f"更新系统hosts文件失败:{str(err) or '请检查权限'}") # 推送实时消息 - self.systemmessage.put(f"更新系统hosts文件失败:{str(err) or '请检查权限'}") + self.systemmessage.put(f"更新系统hosts文件失败:{str(err) or '请检查权限'}", title="Cloudflare IP优选") return err_flag, err_hosts def stop_service(self): diff --git a/plugins/configcenter/__init__.py b/plugins/configcenter/__init__.py index 42b4ed2..8576e73 100644 --- a/plugins/configcenter/__init__.py +++ b/plugins/configcenter/__init__.py @@ -99,7 +99,7 @@ class ConfigCenter(_PluginBase): value = str(value) set_key(env_path, key, value) logger.info("app.env文件写入完成") - self.systemmessage.put("配置中心设置已写入app.env文件,插件关闭") + self.systemmessage.put("配置中心设置已写入app.env文件,插件关闭", title="配置中心") @staticmethod def __parse_params(param_str: str) -> dict: diff --git a/plugins/customhosts/__init__.py b/plugins/customhosts/__init__.py index 4efeaa8..790b887 100644 --- a/plugins/customhosts/__init__.py +++ b/plugins/customhosts/__init__.py @@ -221,7 +221,7 @@ class CustomHosts(_PluginBase): err_hosts.append(host + "\n") logger.error(f"[HOST] 格式转换错误:{str(err)}") # 推送实时消息 - self.systemmessage.put(f"[HOST] 格式转换错误:{str(err)}") + self.systemmessage.put(f"[HOST] 格式转换错误:{str(err)}", title="自定义Hosts") # 写入系统hosts if new_entrys: @@ -236,7 +236,7 @@ class CustomHosts(_PluginBase): err_flag = True logger.error(f"更新系统hosts文件失败:{str(err) or '请检查权限'}") # 推送实时消息 - self.systemmessage.put(f"更新系统hosts文件失败:{str(err) or '请检查权限'}") + self.systemmessage.put(f"更新系统hosts文件失败:{str(err) or '请检查权限'}", title="自定义Hosts") return err_flag, err_hosts def stop_service(self): diff --git a/plugins/customindexer/__init__.py b/plugins/customindexer/__init__.py index 9d799bf..c542311 100644 --- a/plugins/customindexer/__init__.py +++ b/plugins/customindexer/__init__.py @@ -52,7 +52,7 @@ class CustomIndexer(_PluginBase): self.siteshelper.add_indexer(domain, json.loads(jsonstr)) except Exception as err: logger.error(f"自定义索引站点配置错误:{err}") - self.systemmessage.put(f"自定义索引站点配置错误:{err}") + self.systemmessage.put(f"自定义索引站点配置错误:{err}", title="自定义索引站点") continue def get_state(self) -> bool: diff --git a/plugins/dirmonitor/__init__.py b/plugins/dirmonitor/__init__.py index ac83f5d..abf941a 100644 --- a/plugins/dirmonitor/__init__.py +++ b/plugins/dirmonitor/__init__.py @@ -172,7 +172,7 @@ class DirMonitor(_PluginBase): try: if target_path and target_path.is_relative_to(Path(mon_path)): logger.warn(f"{target_path} 是监控目录 {mon_path} 的子目录,无法监控") - self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控") + self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控", title="目录监控") continue except Exception as e: logger.debug(str(e)) @@ -202,7 +202,7 @@ class DirMonitor(_PluginBase): """) else: logger.error(f"{mon_path} 启动目录监控失败:{err_msg}") - self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}") + self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}", title="目录监控") # 运行一次定时服务 if self._onlyonce: diff --git a/plugins/ffmpegthumb/__init__.py b/plugins/ffmpegthumb/__init__.py index e3b8e93..b12454e 100644 --- a/plugins/ffmpegthumb/__init__.py +++ b/plugins/ffmpegthumb/__init__.py @@ -75,7 +75,7 @@ class FFmpegThumb(_PluginBase): name="FFmpeg缩略图") except Exception as e: logger.error(f"FFmpeg缩略图服务启动失败,原因:{str(e)}") - self.systemmessage.put(f"FFmpeg缩略图服务启动失败,原因:{str(e)}") + self.systemmessage.put(f"FFmpeg缩略图服务启动失败,原因:{str(e)}", title="FFmpeg缩略图") if self._onlyonce: logger.info(f"FFmpeg缩略图服务,立即运行一次") self._scheduler.add_job(func=self.__libraryscan, trigger='date', diff --git a/plugins/iyuuauth/__init__.py b/plugins/iyuuauth/__init__.py index 0eadde9..3993afd 100644 --- a/plugins/iyuuauth/__init__.py +++ b/plugins/iyuuauth/__init__.py @@ -47,15 +47,15 @@ class IyuuAuth(_PluginBase): if self._enabled: if not self._token or not self._passkey or not self._uid: logger.warn("IYUU站点绑定插件配置不完整,请检查配置!") - self.systemmessage.put("IYUU站点绑定插件配置不完整,请检查配置!") + self.systemmessage.put("IYUU站点绑定插件配置不完整,请检查配置!", title="IYUU站点绑定") return state, message = self.iyuu.bind_site(site=self._site, passkey=self._passkey, uid=self._uid) if not state: logger.warn(f"IYUU站点绑定失败,错误信息:{message}") - self.systemmessage.put(f"IYUU站点绑定失败,错误信息:{message}") + self.systemmessage.put(f"IYUU站点绑定失败,错误信息:{message}", title="IYUU站点绑定") else: logger.info("IYUU站点绑定成功!") - self.systemmessage.put("IYUU站点绑定成功!") + self.systemmessage.put("IYUU站点绑定成功!", title="IYUU站点绑定") self._enabled = False self.update_config({ "enabled": self._enabled, diff --git a/plugins/linkmonitor/__init__.py b/plugins/linkmonitor/__init__.py index 1c6fa87..cef8d7e 100644 --- a/plugins/linkmonitor/__init__.py +++ b/plugins/linkmonitor/__init__.py @@ -131,7 +131,7 @@ class LinkMonitor(_PluginBase): self._dirconf[mon_path] = target_path else: logger.warn(f"{mon_path} 未配置目的目录,将不会进行硬链接") - self.systemmessage.put(f"{mon_path} 未配置目的目录,将不会进行硬链接!") + self.systemmessage.put(f"{mon_path} 未配置目的目录,将不会进行硬链接!", title="实时硬链接") continue # 启用目录监控 @@ -140,7 +140,7 @@ class LinkMonitor(_PluginBase): try: if target_path and target_path.is_relative_to(Path(mon_path)): logger.warn(f"{target_path} 是监控目录 {mon_path} 的子目录,无法监控") - self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控") + self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控", title="实时硬链接") continue except Exception as e: logger.debug(str(e)) @@ -170,7 +170,7 @@ class LinkMonitor(_PluginBase): """) else: logger.error(f"{mon_path} 启动目录监控失败:{err_msg}") - self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}") + self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}", title="实时硬链接") # 运行一次定时服务 if self._onlyonce: diff --git a/plugins/removelink/__init__.py b/plugins/removelink/__init__.py index 45fc27a..156f02a 100644 --- a/plugins/removelink/__init__.py +++ b/plugins/removelink/__init__.py @@ -179,7 +179,7 @@ class RemoveLink(_PluginBase): except Exception as e: err_msg = str(e) logger.error(f"{mon_path} 启动目录监控失败:{err_msg}") - self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}") + self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}", title="清理硬链接") # 更新监控集合 with state_lock: self.state_set = updateState(monitor_dirs) diff --git a/plugins/torrenttransfer/__init__.py b/plugins/torrenttransfer/__init__.py index ccedaa9..d21296e 100644 --- a/plugins/torrenttransfer/__init__.py +++ b/plugins/torrenttransfer/__init__.py @@ -98,11 +98,11 @@ class TorrentTransfer(_PluginBase): # 检查配置 if self._fromtorrentpath and not Path(self._fromtorrentpath).exists(): logger.error(f"源下载器种子文件保存路径不存在:{self._fromtorrentpath}") - self.systemmessage.put(f"源下载器种子文件保存路径不存在:{self._fromtorrentpath}") + self.systemmessage.put(f"源下载器种子文件保存路径不存在:{self._fromtorrentpath}", title="自动转移做种") return if self._fromdownloader == self._todownloader: logger.error(f"源下载器和目的下载器不能相同") - self.systemmessage.put(f"源下载器和目的下载器不能相同") + self.systemmessage.put(f"源下载器和目的下载器不能相同", title="自动转移做种") return # 定时服务 diff --git a/plugins/vcbanimemonitor/__init__.py b/plugins/vcbanimemonitor/__init__.py index 56eb939..150b0e0 100644 --- a/plugins/vcbanimemonitor/__init__.py +++ b/plugins/vcbanimemonitor/__init__.py @@ -222,7 +222,7 @@ class VCBAnimeMonitor(_PluginBase): try: if target_path and target_path.is_relative_to(Path(mon_path)): logger.warn(f"{target_path} 是监控目录 {mon_path} 的子目录,无法监控") - self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控") + self.systemmessage.put(f"{target_path} 是下载目录 {mon_path} 的子目录,无法监控", title="整理VCB动漫压制组作品") continue except Exception as e: logger.debug(str(e)) @@ -252,7 +252,7 @@ class VCBAnimeMonitor(_PluginBase): """) else: logger.error(f"{mon_path} 启动目录监控失败:{err_msg}") - self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}") + self.systemmessage.put(f"{mon_path} 启动目录监控失败:{err_msg}", title="整理VCB动漫压制组作品") # 运行一次定时服务 if self._onlyonce: