Skip to content

Commit 24feb98

Browse files
chore: fix sourcery errs (#79)
1 parent 5796d3f commit 24feb98

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

evmspec/data/_main.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ def _decode_hook_unsafe(cls, typ: Type["Address"], obj: str) -> Self:
130130

131131
@classmethod
132132
def checksum(cls, address: str) -> Self:
133+
# sourcery skip: use-contextlib-suppress
133134
"""Returns the checksummed version of the address.
134135
135136
This function takes a hex address and returns it in the checksummed format
@@ -314,6 +315,7 @@ def datetime(self) -> datetime:
314315

315316

316317
def _decode_hook(typ: Type[_T], obj: object) -> _T:
318+
# sourcery skip: assign-if-exp
317319
"""A generic decode hook for converting objects to specific types.
318320
319321
Args:
@@ -352,6 +354,7 @@ def _decode_hook(typ: Type[_T], obj: object) -> _T:
352354

353355

354356
def _decode_hook_unsafe(typ: Type[_T], obj: object) -> _T:
357+
# sourcery skip: assign-if-exp
355358
if issubclass(typ, (HexBytes, Enum, Decimal)):
356359
return typ(obj) # type: ignore [arg-type, return-value]
357360
elif typ is Address:

0 commit comments

Comments
 (0)