mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-20 22:03:52 +00:00
Description: add lint docstrings for ollama module Issue: the issue https://github.com/langchain-ai/langchain/issues/23188 @baskaryan test: ruff check passed. <img width="311" alt="e94c68ffa93dd518297a95a93de5217" src="https://github.com/user-attachments/assets/e96bf721-e0e3-44de-a50e-206603de398e"> Co-authored-by: Erick Friis <erick@langchain.dev>
19 lines
516 B
Python
19 lines
516 B
Python
"""load multiple Python files specified as command line arguments."""
|
|
import sys
|
|
import traceback
|
|
from importlib.machinery import SourceFileLoader
|
|
|
|
if __name__ == "__main__":
|
|
files = sys.argv[1:]
|
|
has_failure = False
|
|
for file in files:
|
|
try:
|
|
SourceFileLoader("x", file).load_module()
|
|
except Exception:
|
|
has_failure = True
|
|
print(file) # noqa: T201
|
|
traceback.print_exc()
|
|
print() # noqa: T201
|
|
|
|
sys.exit(1 if has_failure else 0)
|