Skip to content

Commit 87b521c

Browse files
committed
fix: better logging
1 parent bc48168 commit 87b521c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

p2p/types.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -446,6 +446,14 @@ func decodeTx(raw []byte) *types.Transaction {
446446
if tx.UnmarshalBinary(bytes) == nil {
447447
return tx
448448
}
449+
450+
log.Warn().
451+
Uint8("type", bytes[0]).
452+
Int("size", len(bytes)).
453+
Str("hash", crypto.Keccak256Hash(bytes).Hex()).
454+
Msg("Failed to decode transaction")
455+
456+
return nil
449457
}
450458

451459
tx := new(types.Transaction)

0 commit comments

Comments
 (0)