This commit is contained in:
Timothy Jaeryang Baek
2026-02-16 15:32:28 -06:00
parent 4896d30281
commit 15b893e651
2 changed files with 5 additions and 7 deletions
-5
View File
@@ -39,11 +39,6 @@ from open_webui.routers.pipelines import (
from open_webui.models.functions import Functions
from open_webui.models.models import Models
from open_webui.utils.plugin import (
load_function_module_by_id,
get_function_module_from_cache,
)
from open_webui.utils.models import get_all_models, check_model_access
from open_webui.utils.payload import convert_payload_openai_to_ollama
from open_webui.utils.response import (
+5 -2
View File
@@ -302,7 +302,10 @@ async def get_all_models(request, refresh: bool = False, user: UserModel = None)
# This ensures each function's DB freshness check runs exactly once,
# not once per (model × function) pair.
for function_id in all_function_ids:
get_function_module_from_cache(request, function_id)
try:
get_function_module_from_cache(request, function_id)
except Exception as e:
log.info(f"Failed to load function module for {function_id}: {e}")
for model in models:
action_ids = [
@@ -337,7 +340,7 @@ async def get_all_models(request, refresh: bool = False, user: UserModel = None)
if filter_function is None:
log.info(f"Filter not found: {filter_id}")
continue
function_module = request.app.state.FUNCTIONS.get(filter_id)
if function_module is None:
log.info(f"Failed to load filter module: {filter_id}")