mirror of
https://github.com/hwchase17/langchain.git
synced 2025-08-31 10:23:18 +00:00
fix: scripts/
errors
This commit is contained in:
@@ -3,11 +3,13 @@ python scripts/release_branch.py anthropic bagatur
|
||||
"""
|
||||
|
||||
import glob
|
||||
import tomllib
|
||||
import toml
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
# Ignoring errors since this script is run in a controlled environment
|
||||
import toml # type: ignore # pyright: ignore[reportMissingModuleSource]
|
||||
import tomllib # type: ignore # pyright: ignore[reportMissingImports]
|
||||
|
||||
|
||||
def main(*args):
|
||||
pkg = args[1]
|
||||
|
@@ -1,12 +1,13 @@
|
||||
"""python scripts/update_mypy_ruff.py"""
|
||||
|
||||
import glob
|
||||
import tomllib
|
||||
import re
|
||||
import subprocess
|
||||
from pathlib import Path
|
||||
|
||||
import toml
|
||||
import subprocess
|
||||
import re
|
||||
# Ignoring errors since this script is run in a controlled environment
|
||||
import toml # type: ignore # pyright: ignore[reportMissingModuleSource]
|
||||
import tomllib # type: ignore # pyright: ignore[reportMissingImports]
|
||||
|
||||
ROOT_DIR = Path(__file__).parents[1]
|
||||
|
||||
@@ -50,10 +51,9 @@ def main():
|
||||
|
||||
to_ignore = {}
|
||||
for l in logs:
|
||||
if re.match("^(.*)\:(\d+)\: error:.*\[(.*)\]", l):
|
||||
path, line_no, error_type = re.match(
|
||||
"^(.*)\:(\d+)\: error:.*\[(.*)\]", l
|
||||
).groups()
|
||||
match = re.match(r"^(.*):(\d+): error:.*\[(.*)\]", l)
|
||||
if match:
|
||||
path, line_no, error_type = match.groups()
|
||||
if (path, line_no) in to_ignore:
|
||||
to_ignore[(path, line_no)].append(error_type)
|
||||
else:
|
||||
|
Reference in New Issue
Block a user