You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
langchain/libs/core/tests/unit_tests/utils
Leonid Ganeline 3ef8b24277
core[patch]: `utils.guard_import` fix (#21133)
Issues (nit): 
1. `utils.guard_import` prints wrong error message when there is an
import `error.` It prints the whole `module_name` but should be only the
first part as the pip package name. E.i. `langchain_core.utils` -> print
not `langchain-core` but `langchain_core.utils`. Also replace '_' with
'-' in the pip package name.
2. it does not handle the `ModuleNotFoundError` which raised if
`guard_import("wrong_module")`

Fixed issues; added ut-s. Controversial: I've reraised
`ModuleNotFoundError` as `ImportError`, since in case of the error, the
proposed action is the same - we need to install a missed package.
5 months ago
..
__init__.py Separate out langchain_core package (#13577) 10 months ago
test_function_calling.py Ignore self/cls from required args of class functions in convert_to_openai_tool (#20691) 5 months ago
test_html.py core[patch]: Enhance link extraction with query parameters (#20259) 5 months ago
test_imports.py core[minor]: Image prompt template (#14263) 8 months ago
test_iter.py Separate out langchain_core package (#13577) 10 months ago
test_json_schema.py core[patch]: fixed circular dependency with json schema (#18657) 6 months ago
test_rm_titles.py core: update _rm_titles to account for title argument name bug (#19036) 6 months ago
test_utils.py core[patch]: `utils.guard_import` fix (#21133) 5 months ago