mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-14 23:21:35 +00:00
refactor(azure-ocr): move urllib.parse.quote to module imports
Remove inline import in get_complete_url; quote is stdlib with no circular import risk per project style. Made-with: Cursor
This commit is contained in:
parent
089ca5fc0f
commit
a84c27674f
1 changed files with 1 additions and 2 deletions
|
|
@ -11,6 +11,7 @@ import asyncio
|
|||
import re
|
||||
import time
|
||||
from typing import Any, Dict, Optional
|
||||
from urllib.parse import quote
|
||||
|
||||
import httpx
|
||||
|
||||
|
|
@ -227,8 +228,6 @@ class AzureDocumentIntelligenceOCRConfig(BaseOCRConfig):
|
|||
# `optional_params` has already been normalized in `map_ocr_params`.
|
||||
pages = optional_params.get("pages") if optional_params else None
|
||||
if pages:
|
||||
from urllib.parse import quote
|
||||
|
||||
url += f"&pages={quote(str(pages), safe=',-')}"
|
||||
|
||||
return url
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue