cli[patch]: ruff 0.5 (#23833)

This commit is contained in:
Bagatur
2024-07-03 14:33:15 -04:00
committed by GitHub
parent 55f6f91f17
commit a4798802ef
19 changed files with 42 additions and 29 deletions

View File

@@ -1,6 +1,7 @@
"""
Develop integration packages for LangChain.
"""
import re
import shutil
import subprocess
@@ -154,7 +155,8 @@ def create_doc(
str,
typer.Option(
help=(
"The type of component. Currently only 'ChatModel', 'DocumentLoader' supported."
"The type of component. Currently only 'ChatModel', 'DocumentLoader' "
"supported."
),
),
] = "ChatModel",

View File

@@ -10,6 +10,7 @@ This codemod deals with the following cases:
4. `from pydantic.settings import BaseSettings as <name>` # TODO: This is not working.
5. `import pydantic` -> `pydantic.BaseSettings`
"""
from __future__ import annotations
import json

View File

@@ -1,4 +1,5 @@
"""Generate migrations from langchain to langchain-community or core packages."""
import importlib
import inspect
import pkgutil

View File

@@ -1,4 +1,5 @@
"""Generate migrations for partner packages."""
import importlib
from typing import List, Tuple

View File

@@ -1,4 +1,5 @@
"""Migrate LangChain to the most recent version."""
# Adapted from bump-pydantic
# https://github.com/pydantic/bump-pydantic
import difflib