env_var_is_set() — langchain Function Reference
Architecture documentation for the env_var_is_set() function in env.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 431b90be_b257_0a34_7267_d8149e0238f3["env_var_is_set()"] 359da5b8_85a8_468a_12ae_f45ea1dc33e4["env.py"] 431b90be_b257_0a34_7267_d8149e0238f3 -->|defined in| 359da5b8_85a8_468a_12ae_f45ea1dc33e4 style 431b90be_b257_0a34_7267_d8149e0238f3 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/langchain_core/utils/env.py lines 9–23
def env_var_is_set(env_var: str) -> bool:
"""Check if an environment variable is set.
Args:
env_var: The name of the environment variable.
Returns:
`True` if the environment variable is set, `False` otherwise.
"""
return env_var in os.environ and os.environ[env_var] not in {
"",
"0",
"false",
"False",
}
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does env_var_is_set() do?
env_var_is_set() is a function in the langchain codebase, defined in libs/core/langchain_core/utils/env.py.
Where is env_var_is_set() defined?
env_var_is_set() is defined in libs/core/langchain_core/utils/env.py at line 9.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free