ferranbt / fastssz

Fast Ethereum2.0 SSZ encoder/decoder
MIT License
74 stars 44 forks source link

Log Field Name of Errors in HashTreeRoot #83

Closed rauljordan closed 2 years ago

rauljordan commented 2 years ago

Sometimes, when hash tree root encounters the following error:

error=bytes array does not have the correct length

It could be very useful to return the field name as part of the error message. This can be done via codegen

ferranbt commented 2 years ago

Would this work? https://github.com/ferranbt/fastssz/pull/81