Skip to content

Commit 4d6f6cc

Browse files
committed
fix(deps): update dependency versions and handle binary files
Update minimum versions for cyclopts, liblaf-grapes and litellm dependencies to ensure compatibility with latest features. Add error handling when reading files to detect @generated markers, skipping binary files that would cause UnicodeDecodeError.
1 parent 0662a32 commit 4d6f6cc

File tree

3 files changed

+23
-20
lines changed

3 files changed

+23
-20
lines changed

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@ classifiers = [
5252
"Typing :: Typed",
5353
]
5454
dependencies = [
55-
"cyclopts>=3.17.0,<4",
55+
"cyclopts>=3.19.0,<4",
5656
"gitpython>=3.1.44,<4",
5757
"jinja2>=3.1.6,<4",
5858
"lazy-loader>=0.4,<0.5",
59-
"liblaf-grapes>=0.2.0,<0.3",
60-
"litellm>=1.72.1,<2",
59+
"liblaf-grapes>=0.2.2,<0.3",
60+
"litellm>=1.72.4,<2",
6161
"loguru>=0.7.3,<0.8",
6262
"platformdirs>=4.3.8,<5",
6363
"pydantic-settings>=2.9.1,<3",

src/liblaf/lime/tools/_git.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,14 @@ def list_generated_files(self) -> Generator[Path]:
5252
for file in self.ls_files():
5353
if file.is_relative_to("template/"): # skip copier template files
5454
continue
55-
with file.open("r") as fp:
56-
for _, line in zip(range(5), fp, strict=False):
57-
if "@generated" in line:
58-
yield file
59-
break
55+
try:
56+
with file.open("r") as fp:
57+
for _, line in zip(range(5), fp, strict=False):
58+
if "@generated" in line:
59+
yield file
60+
break
61+
except UnicodeDecodeError:
62+
continue
6063

6164
def ls_files(self) -> list[Path]:
6265
output: str = self.repo.git.ls_files()

uv.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)