From bc2fbbbfba2b13437284f1fb32d3f9f3ab5d0e61 Mon Sep 17 00:00:00 2001 From: "yunlu.wen" Date: Tue, 10 Mar 2026 10:38:16 +0800 Subject: [PATCH] fix discussion --- api/services/enterprise/plugin_manager_service.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/api/services/enterprise/plugin_manager_service.py b/api/services/enterprise/plugin_manager_service.py index c8e2870663..2769edd765 100644 --- a/api/services/enterprise/plugin_manager_service.py +++ b/api/services/enterprise/plugin_manager_service.py @@ -66,19 +66,16 @@ class PluginManagerService: def try_pre_uninstall_plugin(cls, body: PreUninstallPluginRequest): try: # the invocation must be synchronous. - EnterprisePluginManagerRequest.send_request( # pyright: ignore[reportUnknownMemberType] + EnterprisePluginManagerRequest.send_request( "POST", "/pre-uninstall-plugin", - json=body.model_dump(), # pyright: ignore[reportUnknownArgumentType, reportUnknownMemberType] + json=body.model_dump(), raise_for_status=True, timeout=dify_config.ENTERPRISE_REQUEST_TIMEOUT, ) - except Exception as e: + except Exception: logger.exception( - """ - failed to perform pre uninstall plugin hook. tenant_id: %s, plugin_unique_identifier: %s, - this may cause plugin to be automatically garbage collected - """, + "failed to perform pre uninstall plugin hook. tenant_id: %s, plugin_unique_identifier: %s, ", body.tenant_id, body.plugin_unique_identifier, )