mirror of
https://github.com/langchain-ai/langchain.git
synced 2026-10-05 01:15:09 +03:00
fix(deepseek,infra): resolve compatible minimum OpenAI dependencies, bump min ver (#40738)
- The [DeepSeek release check](https://github.com/langchain-ai/langchain/actions/runs/35686046493/job/106613011631) downgraded core to 1.4.7 while retaining local OpenAI 1.6.3, which requires core 1.6.4. Include `langchain-openai` in release minimum-version selection so both dependencies are resolved together; preserve local packages during PR checks. - Raise DeepSeek's OpenAI minimum to 1.3.1: testing the old 1.1.0 floor exposes missing model-profile behavior and package-version metadata. Add regression coverage for release and PR dependency selection. ## Release note `langchain-deepseek` now requires `langchain-openai>=1.3.1` for model profiles and package-version metadata. Made by [Open SWE](https://github.com/langchain-ai/open-swe) · [view thread](https://openswe.vercel.app/agents/ed7f0398-e808-5f5b-9eb4-0521c82fff7f) · openai:gpt-6-astra (low) Co-authored-by: Mason <mdrxy@users.noreply.github.com> Co-authored-by: open-swe[bot] <open-swe@users.noreply.github.com>
This commit is contained in:
3 files changed
+35
-1
No files matched your search
@@ -19,6 +19,7 @@ from packaging.version import Version, parse
|
||||
|
||||
MIN_VERSION_LIBS = [
|
||||
"langchain-core",
|
||||
"langchain-openai",
|
||||
"langchain",
|
||||
"langchain-text-splitters",
|
||||
"numpy",
|
||||
@@ -31,6 +32,7 @@ MIN_VERSION_LIBS = [
|
||||
# multiple libs
|
||||
SKIP_IF_PULL_REQUEST = [
|
||||
"langchain-core",
|
||||
"langchain-openai",
|
||||
"langchain-text-splitters",
|
||||
"langchain",
|
||||
]
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
"""Regression tests for release minimum dependency selection."""
|
||||
|
||||
from pathlib import Path
|
||||
from unittest.mock import patch
|
||||
|
||||
import pytest
|
||||
from get_min_versions import get_min_version_from_toml
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
("versions_for", "expected"),
|
||||
[
|
||||
("release", {"langchain-core": "1.4.7", "langchain-openai": "1.1.0"}),
|
||||
("pull_request", {}),
|
||||
],
|
||||
)
|
||||
def test_openai_partner_minimum_versions(
|
||||
tmp_path: Path, versions_for: str, expected: dict[str, str]
|
||||
) -> None:
|
||||
manifest = tmp_path / "pyproject.toml"
|
||||
manifest.write_text(
|
||||
'[project]\ndependencies = ["langchain-core>=1.4.7,<2.0.0", '
|
||||
'"langchain-openai>=1.1.0,<2.0.0"]\n'
|
||||
)
|
||||
versions = {
|
||||
"langchain-core": ["1.6.4", "1.4.7", "1.1.0"],
|
||||
"langchain-openai": ["1.6.3", "1.1.0", "1.0.0"],
|
||||
}
|
||||
with patch("get_min_versions.get_pypi_versions", side_effect=versions.__getitem__):
|
||||
assert (
|
||||
get_min_version_from_toml(str(manifest), versions_for, "3.11") == expected
|
||||
)
|
||||
@@ -24,7 +24,7 @@ version = "1.1.1"
|
||||
requires-python = ">=3.10.0,<4.0.0"
|
||||
dependencies = [
|
||||
"langchain-core>=1.4.7,<2.0.0",
|
||||
"langchain-openai>=1.1.0,<2.0.0",
|
||||
"langchain-openai>=1.3.1,<2.0.0",
|
||||
]
|
||||
|
||||
[project.urls]
|
||||
|
||||
Reference in new issue
Block a user