fix failures

This commit is contained in:
senstella
2026-01-18 03:29:42 +09:00
parent ca85a52839
commit 6560ac93f1
6 changed files with 243 additions and 65 deletions

18
main.py
View File

@@ -25,7 +25,11 @@ def _inspect_patch(path: str) -> None:
controls = 0
with PatchReader.open(path) as reader:
compression = reader.header.compression.algorithm if reader.header and reader.header.compression else None
compression = (
reader.header.compression.algorithm
if reader.header and reader.header.compression
else None
)
for entry in reader.iter_file_entries():
files += 1
if entry.is_rsync():
@@ -50,7 +54,11 @@ def _inspect_patch(path: str) -> None:
def _inspect_signature(path: str) -> None:
blocks = 0
with SignatureReader.open(path) as reader:
compression = reader.header.compression.algorithm if reader.header and reader.header.compression else None
compression = (
reader.header.compression.algorithm
if reader.header and reader.header.compression
else None
)
for _ in reader.iter_block_hashes():
blocks += 1
print("signature")
@@ -61,7 +69,11 @@ def _inspect_signature(path: str) -> None:
def _inspect_manifest(path: str) -> None:
hashes = 0
with ManifestReader.open(path) as reader:
compression = reader.header.compression.algorithm if reader.header and reader.header.compression else None
compression = (
reader.header.compression.algorithm
if reader.header and reader.header.compression
else None
)
for _ in reader.iter_block_hashes():
hashes += 1
print("manifest")