Skip to content

Commit

Permalink
chore: fix code according to ruff 0.8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
qkaiser committed Nov 27, 2024
1 parent 645dbfb commit 3d3c47b
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
18 changes: 16 additions & 2 deletions unblob/handlers/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
from ..models import DirectoryHandlers, Handlers
from .archive import ar, arc, arj, cab, cpio, dmg, rar, sevenzip, stuffit, tar, zip
from .archive import (
ar,
arc,
arj,
cab,
cpio,
dmg,
rar,
sevenzip,
stuffit,
tar,
)
from .archive import (
zip as ziparchive,
)
from .archive.autel import ecc
from .archive.dlink import encrpted_img, shrs
from .archive.engeniustech import engenius
Expand Down Expand Up @@ -80,7 +94,7 @@
cpio.BinaryHandler,
sevenzip.SevenZipHandler,
rar.RarHandler,
zip.ZIPHandler,
ziparchive.ZIPHandler,
dmg.DMGHandler,
iso9660.ISO9660FSHandler,
stuffit.StuffItSITHandler,
Expand Down
3 changes: 1 addition & 2 deletions unblob/handlers/filesystem/yaffs.py
Original file line number Diff line number Diff line change
Expand Up @@ -408,8 +408,7 @@ def auto_detect(self) -> YAFFSConfig:
# Sanity check the spare size, make sure it looks legit
if config.spare_size not in VALID_SPARE_SIZES:
raise InvalidInputFormat(
"Auto-detection failed: Detected an unlikely spare size: %d"
% config.spare_size
f"Auto-detection failed: Detected an unlikely spare size: {config.spare_size}"
)

return config
Expand Down
2 changes: 1 addition & 1 deletion unblob/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@


@pytest.fixture(scope="session", autouse=True)
def configure_logging(tmp_path_factory): # noqa: PT004
def configure_logging(tmp_path_factory):
extract_root = tmp_path_factory.mktemp("extract")
log_path = tmp_path_factory.mktemp("logs") / "unblob.log"
configure_logger(verbosity_level=3, extract_root=extract_root, log_path=log_path)
Expand Down

0 comments on commit 3d3c47b

Please sign in to comment.