diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b68fe0b..8b28c32 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -42,7 +42,7 @@ repos: args: ["--line-length=132"] - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.16.0 + rev: v0.16.1 hooks: - id: ruff args: ["--fix", "--exit-non-zero-on-fix"] diff --git a/objutils/dwarf/__init__.py b/objutils/dwarf/__init__.py index 2b9f710..50e1ff8 100644 --- a/objutils/dwarf/__init__.py +++ b/objutils/dwarf/__init__.py @@ -300,7 +300,6 @@ class Readers: """ - @dataclass class DIEAttribute: """Parsed DIE attribute with value. diff --git a/objutils/dwarf/encoding.py b/objutils/dwarf/encoding.py index 931eb7a..1c8fabe 100644 --- a/objutils/dwarf/encoding.py +++ b/objutils/dwarf/encoding.py @@ -64,12 +64,10 @@ class ULEBError(ConstructError): """Raised when ULEB128 parsing or building encounters an error.""" - class SLEBError(ConstructError): """Raised when SLEB128 parsing or building encounters an error.""" - @singleton class ULEB(Construct): """Unsigned LEB128 (Little-Endian Base-128) Variable-Length Integer. diff --git a/objutils/dwarf/readers.py b/objutils/dwarf/readers.py index f31dec2..a91d657 100644 --- a/objutils/dwarf/readers.py +++ b/objutils/dwarf/readers.py @@ -69,7 +69,6 @@ class Readers: """ - class DwarfReaders: """High-Level DWARF Data Reader Interface. diff --git a/objutils/elf/model.py b/objutils/elf/model.py index b6478b4..7f5daee 100644 --- a/objutils/elf/model.py +++ b/objutils/elf/model.py @@ -1183,7 +1183,6 @@ class DebugInformation(Base, RidMixIn): """ - class CompilationUnit(Base, RidMixIn): __tablename__ = "compilationunit" """ORM model for DWARF Compilation Unit (CU). @@ -1193,7 +1192,6 @@ class CompilationUnit(Base, RidMixIn): """ - def calculateCacheSize(value: int) -> int: """Convert cache size in bytes to SQLite PRAGMA format. diff --git a/objutils/hexfile.py b/objutils/hexfile.py index 0a194f9..8f4806b 100644 --- a/objutils/hexfile.py +++ b/objutils/hexfile.py @@ -335,32 +335,26 @@ class HexFileError(Exception): """Base exception for all hex file operations.""" - class ParseError(HexFileError): """Base for parsing-related errors.""" - class InvalidRecordTypeError(ParseError): """Raised when record type is not recognized.""" - class InvalidRecordLengthError(ParseError): """Raised when record length doesn't match data.""" - class InvalidRecordChecksumError(ParseError): """Raised when checksum validation fails.""" - class AddressRangeToLargeError(HexFileError): """Raised when address exceeds format capabilities.""" - # Deprecated alias for backward compatibility Invalidrecord_typeError = InvalidRecordTypeError diff --git a/objutils/registry.py b/objutils/registry.py index d71b5ca..d71773f 100644 --- a/objutils/registry.py +++ b/objutils/registry.py @@ -211,7 +211,6 @@ class CodecDoesNotExistError(Exception): """ - class CodecAlreadyExistError(Exception): """Raised when attempting to register a format that already exists. @@ -230,7 +229,6 @@ class CodecAlreadyExistError(Exception): """ - class Codec(NamedTuple): """Container for format reader, writer, and metadata.