Skip to content

Commit

Permalink
fix: ds-note decoding
Browse files Browse the repository at this point in the history
  • Loading branch information
banteg authored May 30, 2024
1 parent a7daa70 commit 84810c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion brownie/network/event.py
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ def _decode_ds_note(log, contract): # type: ignore
if selector.hex() not in contract.selectors or sum(tail):
return
name = contract.selectors[selector.hex()]
data = bytes.fromhex(log.data[2:])
data = bytes.fromhex(log.data[2:]) if isinstance(log.data, str) else log.data
# data uses ABI encoding of [uint256, bytes] or [bytes] in different versions
# instead of trying them all, assume the payload starts from selector
try:
Expand Down

0 comments on commit 84810c5

Please sign in to comment.