fix(langchain-classic): pass default to config.getoption (#34034)

Fixes #34033

---------

Co-authored-by: Mason Daugherty <mason@langchain.dev>
This commit is contained in:
Sarah Clark
2025-12-27 14:36:51 -08:00
committed by GitHub
parent 30ac1da0de
commit 10de0a5364
2 changed files with 5 additions and 5 deletions

View File

@@ -80,8 +80,8 @@ def pytest_collection_modifyitems(config: pytest.Config, items: Sequence[pytest.
# Used to avoid repeated calls to `util.find_spec`
required_pkgs_info: dict[str, bool] = {}
only_extended = config.getoption("--only-extended") or False
only_core = config.getoption("--only-core") or False
only_extended = config.getoption("--only-extended", default=False)
only_core = config.getoption("--only-core", default=False)
if only_extended and only_core:
msg = "Cannot specify both `--only-extended` and `--only-core`."