The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
infra: Clear cache for env-var checks (#26073)
William FH262e19b15db4
diff --git a/libs/community/poetry.lock b/libs/community/poetry.lockindex a90e3edec8..68b5adc102 100644--- a/libs/community/poetry.lock+++ b/libs/community/poetry.lock@@ -1772,7 +1772,7 @@ develop = true[package.dependencies]jsonpatch = "^1.33"-langsmith = "^0.1.75"+langsmith = "^0.1.112"packaging = ">=23.2,<25"pydantic = [{version = ">=1,<3", markers = "python_full_version < \"3.12.4\""},@@ -1799,6 +1799,7 @@ develop = truehttpx = "^0.27.0"langchain-core = ">=0.1.40,<0.3"pytest = ">=7,<9"+syrupy = "^4"[package.source]type = "directory"@@ -1822,13 +1823,13 @@ url = "../text-splitters"[[package]]name = "langsmith"-version = "0.1.110"+version = "0.1.116"description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform."optional = falsepython-versions = "<4.0,>=3.8.1"files = [- {file = "langsmith-0.1.110-py3-none-any.whl", hash = "sha256:316d279e3853f5e90e462f9c035eeb468d042f2a21a269c1102d65f3dccdc334"},- {file = "langsmith-0.1.110.tar.gz", hash = "sha256:9a619dfe22a67a05a05091f0677b9c842499faec5f051b31afcd901b6627d0a3"},+ {file = "langsmith-0.1.116-py3-none-any.whl", hash = "sha256:4b5ea64c81ba5ca309695c85dc3fb4617429a985129ed5d9eca00d1c9d6483f4"},+ {file = "langsmith-0.1.116.tar.gz", hash = "sha256:5ccd7f5c1840f7c507ab3ee56334a1391de28c8bf72669782e2d82cafeefffa7"},][package.dependencies]@@ -2481,8 +2482,8 @@ files = [[package.dependencies]numpy = [{version = ">=1.20.3", markers = "python_version < \"3.10\""},- {version = ">=1.21.0", markers = "python_version >= \"3.10\" and python_version < \"3.11\""},{version = ">=1.23.2", markers = "python_version >= \"3.11\""},+ {version = ">=1.21.0", markers = "python_version >= \"3.10\" and python_version < \"3.11\""},]python-dateutil = ">=2.8.2"pytz = ">=2020.1"@@ -4323,4 +4324,4 @@ type = ["pytest-mypy"][metadata]lock-version = "2.0"python-versions = ">=3.8.1,<4.0"-content-hash = "b69b2186cc152c64945d8000e883e92d7872a38b7113f60b1db5c7e1c9aed7c6"+content-hash = "83bd930c36648406317fb87fa8205f67e41c89b27c30cb25b9e66a476d0e5e08"diff --git a/libs/community/pyproject.toml b/libs/community/pyproject.tomlindex 3a4758e5cf..bd50a7352d 100644--- a/libs/community/pyproject.toml+++ b/libs/community/pyproject.toml@@ -38,7 +38,7 @@ PyYAML = ">=5.3"aiohttp = "^3.8.3"tenacity = "^8.1.0,!=8.4.0"dataclasses-json = ">= 0.5.7, < 0.7"-langsmith = "^0.1.0"+langsmith = "^0.1.112"[[tool.poetry.dependencies.numpy]]version = "^1"python = "<3.12"diff --git a/libs/community/tests/unit_tests/callbacks/test_callback_manager.py b/libs/community/tests/unit_tests/callbacks/test_callback_manager.pyindex 69821d2de6..dbc414f053 100644--- a/libs/community/tests/unit_tests/callbacks/test_callback_manager.py+++ b/libs/community/tests/unit_tests/callbacks/test_callback_manager.py@@ -7,6 +7,7 @@ from langchain_core.callbacks.manager import CallbackManager, trace_as_chain_grofrom langchain_core.outputs import LLMResultfrom langchain_core.tracers.langchain import LangChainTracer, wait_for_all_tracersfrom langchain_core.utils.pydantic import get_fields+from langsmith import utils as ls_utilsfrom langchain_community.callbacks import get_openai_callbackfrom langchain_community.callbacks.manager import get_bedrock_anthropic_callback@@ -17,6 +18,8 @@ def test_callback_manager_configure_context_vars(monkeypatch: pytest.MonkeyPatch,) -> None:"""Test callback manager configuration."""+ ls_utils.get_env_var.cache_clear()+ ls_utils.get_tracer_project.cache_clear()monkeypatch.setenv("LANGCHAIN_TRACING_V2", "true")monkeypatch.setenv("LANGCHAIN_TRACING", "false")monkeypatch.setenv("LANGCHAIN_API_KEY", "foo")diff --git a/libs/core/poetry.lock b/libs/core/poetry.lockindex 6b99c525c9..d4327070cf 100644--- a/libs/core/poetry.lock+++ b/libs/core/poetry.lock@@ -1253,13 +1253,13 @@ url = "../text-splitters"[[package]]name = "langsmith"-version = "0.1.106"+version = "0.1.113"description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform."optional = falsepython-versions = "<4.0,>=3.8.1"files = [- {file = "langsmith-0.1.106-py3-none-any.whl", hash = "sha256:a418161c98de72ee2c6eea6667c6217814b67db4b9a3a024788013384216ff35"},- {file = "langsmith-0.1.106.tar.gz", hash = "sha256:64a890a05640d64692f5515ebb444b0457332a9cf9e7605c4651de6737a7d3a0"},+ {file = "langsmith-0.1.113-py3-none-any.whl", hash = "sha256:0071d034fbe54cc3574f382b062c4b4f09931dfe7b703146900b7918a7f6c785"},+ {file = "langsmith-0.1.113.tar.gz", hash = "sha256:369efa53352bdc4f27d5c8b7f4f802b32492e55511c7fbeeaea143dbfdf0ee06"},][package.dependencies]@@ -3220,4 +3220,4 @@ type = ["pytest-mypy"][metadata]lock-version = "2.0"python-versions = ">=3.8.1,<4.0"-content-hash = "e86e28d75744b77f8c2173b58e950c2d23c95cacad8ee5d3110309c4248f7c09"+content-hash = "db22fd24cc4409baa802efebb4a73e8effd50befe465428d7946d91dccbb9563"diff --git a/libs/core/pyproject.toml b/libs/core/pyproject.tomlindex ae040a018b..25c5bc1544 100644--- a/libs/core/pyproject.toml+++ b/libs/core/pyproject.toml@@ -24,7 +24,7 @@ ignore_missing_imports = true[tool.poetry.dependencies]python = ">=3.8.1,<4.0"-langsmith = "^0.1.75"+langsmith = "^0.1.112"tenacity = "^8.1.0,!=8.4.0"jsonpatch = "^1.33"PyYAML = ">=5.3"diff --git a/libs/core/tests/unit_tests/runnables/test_tracing_interops.py b/libs/core/tests/unit_tests/runnables/test_tracing_interops.pyindex 71744bf795..b958636a91 100644--- a/libs/core/tests/unit_tests/runnables/test_tracing_interops.py+++ b/libs/core/tests/unit_tests/runnables/test_tracing_interops.py@@ -6,6 +6,7 @@ from unittest.mock import MagicMock, patchimport pytestfrom langsmith import Client, traceablefrom langsmith.run_helpers import tracing_context+from langsmith.utils import get_env_varfrom langchain_core.runnables.base import RunnableLambda, RunnableParallelfrom langchain_core.tracers.langchain import LangChainTracer@@ -31,6 +32,7 @@ def _get_posts(client: Client) -> list:def test_config_traceable_handoff() -> None:+ get_env_var.cache_clear()mock_session = MagicMock()mock_client_ = Client(session=mock_session, api_key="test", auto_batch_tracing=False@@ -186,6 +188,7 @@ def test_tracing_enable_disable(def my_func(a: int) -> int:return a + 1+ get_env_var.cache_clear()env_on = env == "true"with patch.dict("os.environ", {"LANGSMITH_TRACING": env}):with tracing_context(enabled=enabled):diff --git a/libs/core/tests/unit_tests/tracers/test_langchain.py b/libs/core/tests/unit_tests/tracers/test_langchain.pyindex fa22e488e9..6610624dd4 100644--- a/libs/core/tests/unit_tests/tracers/test_langchain.py+++ b/libs/core/tests/unit_tests/tracers/test_langchain.py@@ -9,6 +9,7 @@ from uuid import UUIDimport pytestfrom langsmith import Clientfrom langsmith.run_trees import RunTree+from langsmith.utils import get_env_var, get_tracer_projectfrom langchain_core.outputs import LLMResultfrom langchain_core.tracers.langchain import LangChainTracer@@ -130,6 +131,8 @@ class LangChainProjectNameTest(unittest.TestCase):]for case in cases:+ get_env_var.cache_clear()+ get_tracer_project.cache_clear()with self.subTest(msg=case.test_name):with pytest.MonkeyPatch.context() as mp:for k, v in case.envvars.items():