mirror of
https://github.com/tiennm99/litellm.git
synced 2026-08-03 02:20:15 +00:00
style: move import os to module level, fix import ordering
This commit is contained in:
@@ -5,14 +5,15 @@ CRUD ENDPOINTS FOR GUARDRAILS
|
||||
import concurrent.futures
|
||||
import inspect
|
||||
import json
|
||||
import os
|
||||
from datetime import datetime, timezone
|
||||
from typing import Any, Dict, List, Optional, Type, TypeVar, Union, cast
|
||||
from urllib.parse import urlparse
|
||||
|
||||
from fastapi import APIRouter, Depends, HTTPException
|
||||
from pydantic import BaseModel
|
||||
|
||||
from litellm.proxy.common_utils.path_utils import safe_join
|
||||
from pydantic import BaseModel
|
||||
|
||||
from litellm._logging import verbose_proxy_logger
|
||||
from litellm.constants import DEFAULT_MAX_RECURSE_DEPTH
|
||||
@@ -1350,8 +1351,6 @@ async def get_category_yaml(category_name: str):
|
||||
Returns:
|
||||
The raw YAML or JSON content of the category file with file type indicator
|
||||
"""
|
||||
import os
|
||||
|
||||
# Get the categories directory path
|
||||
categories_dir = os.path.join(
|
||||
os.path.dirname(__file__),
|
||||
@@ -1408,8 +1407,6 @@ async def get_major_airlines():
|
||||
Get the major airlines list from IATA (competitor intent, airline type).
|
||||
Returns airline id, match variants (pipe-separated), and tags.
|
||||
"""
|
||||
import os
|
||||
|
||||
airlines_path = os.path.join(
|
||||
os.path.dirname(__file__),
|
||||
"guardrail_hooks",
|
||||
|
||||
Reference in New Issue
Block a user