[Infra] Packaging: Drop floor-check workflow + bound importlib-metadata

Removing the new check-dependency-floors.yml workflow. It only fires when
pyproject.toml changes, which is rare; for those PRs, a maintainer can
run the same check by hand with one command. Documented that command in
a pyproject.toml comment next to the deps.

Also adds the missing upper bound on importlib-metadata (>=8.0.0,<9.0)
for consistency with every other entry in the list.
This commit is contained in:
Yuneng Jiang
2026-05-05 16:51:56 -07:00
parent eff0f8c630
commit 201fa5d42b
3 changed files with 5 additions and 121 deletions
@@ -1,117 +0,0 @@
name: Check dependency floors
on:
pull_request:
paths:
- 'pyproject.toml'
- '.github/workflows/check-dependency-floors.yml'
workflow_dispatch:
permissions:
contents: read
jobs:
resolve-and-import:
name: Install at lowest-direct + smoke-import litellm
runs-on: ubuntu-latest
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.13"]
steps:
- name: Checkout PR
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Set up uv
uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7
with:
version: "0.10.9"
enable-cache: false
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Resolve litellm core deps at floor versions
run: |
uv venv --python ${{ matrix.python-version }} /tmp/floor-venv
uv pip install --python /tmp/floor-venv/bin/python --resolution=lowest-direct .
- name: Smoke-import litellm at floor versions
run: |
/tmp/floor-venv/bin/python <<'PY'
import importlib
# Import the SDK itself.
import litellm # noqa: F401
# Import every openai-namespace symbol the codebase actually uses
# at runtime. If a floor is set lower than the version that
# introduced any of these, the install will silently succeed and
# then fail at runtime in customer code. This list mirrors the
# openai imports under litellm/ — keep it in sync.
import openai # noqa: F401
from openai import ( # noqa: F401
AsyncAzureOpenAI,
AsyncOpenAI,
AzureOpenAI,
OpenAI,
APIError,
APITimeoutError,
Omit,
)
from openai.types.responses import ( # noqa: F401
ResponseFunctionToolCall,
ResponseInputImageParam,
ResponseOutputMessage,
ResponseReasoningItem,
)
from openai.types.responses.response import ( # noqa: F401
IncompleteDetails,
Response,
ResponseOutputItem,
Tool,
ToolChoice,
)
from openai.types.responses.response_output_item import ( # noqa: F401
ResponseApplyPatchToolCall,
)
from openai.types.responses.response_text_config_param import ( # noqa: F401
ResponseTextConfigParam,
)
from openai.types.responses.tool_param import ( # noqa: F401
FunctionToolParam,
)
# Sanity-check the other direct deps load.
for mod in (
"pydantic",
"httpx",
"aiohttp",
"tokenizers",
"tiktoken",
"click",
"jinja2",
"jsonschema",
"importlib_metadata",
"fastuuid",
"dotenv",
):
importlib.import_module(mod)
print("All floor-version imports OK")
PY
- name: Report resolved versions
if: always()
run: |
/tmp/floor-venv/bin/python -c "
from importlib.metadata import version
for pkg in ['litellm', 'openai', 'pydantic', 'httpx', 'aiohttp', 'tokenizers', 'tiktoken', 'click', 'jinja2', 'jsonschema', 'importlib-metadata', 'fastuuid', 'python-dotenv']:
try:
print(f'{pkg}: {version(pkg)}')
except Exception as e:
print(f'{pkg}: <not installed> ({e})')
"
+4 -3
View File
@@ -11,14 +11,15 @@ authors = [
]
dependencies = [
# Ranges (not exact pins) so SDK consumers can coexist with their other
# deps. Reproducibility for our Docker/CI comes from `uv.lock`. The
# `dependency-floors` CI job validates the floors actually install.
# deps. Reproducibility for our Docker/CI comes from `uv.lock`.
# When changing a floor, verify it installs + imports on every supported
# Python with: `uv pip install --resolution=lowest-direct .`
"fastuuid>=0.14.0,<1.0",
"httpx>=0.28.0,<1.0",
"openai>=2.20.0,<3.0.0",
"python-dotenv>=1.0.0,<2.0",
"tiktoken>=0.8.0,<1.0",
"importlib-metadata>=8.0.0",
"importlib-metadata>=8.0.0,<9.0",
"tokenizers>=0.21.0,<1.0",
"click>=8.0.0,<9.0",
"jinja2>=3.1.0,<4.0",
Generated
+1 -1
View File
@@ -3290,7 +3290,7 @@ requires-dist = [
{ name = "grpcio", marker = "extra == 'proxy-runtime'", specifier = "==1.78.0" },
{ name = "gunicorn", marker = "extra == 'proxy'", specifier = "==23.0.0" },
{ name = "httpx", specifier = ">=0.28.0,<1.0" },
{ name = "importlib-metadata", specifier = ">=8.0.0" },
{ name = "importlib-metadata", specifier = ">=8.0.0,<9.0" },
{ name = "jinja2", specifier = ">=3.1.0,<4.0" },
{ name = "jsonschema", specifier = ">=4.0.0,<5.0" },
{ name = "langfuse", marker = "extra == 'proxy-runtime'", specifier = "==2.59.7" },