ApeWorX / eip712

Message classes for typed structured data hashing and signing in Ethereum
Apache License 2.0
42 stars 19 forks source link

fix: display correct type name in err #7

Closed antazoey closed 3 years ago

antazoey commented 3 years ago

The error message always said type before and was confusing. Now, it says the correct type name. The following is a demo code snippet of what I mean:

>>> typ = str
>>> typ.__name__
'str'
>>> typ.__class__.__name__
'type'
fubuloubu commented 3 years ago

although this might not work with complex subclasses of EIP712Type

antazoey commented 3 years ago

although this might not work with complex subclasses of EIP712Type

Hmm.. Do you have any example this? What specifically are you suspicious won't work?

fubuloubu commented 3 years ago

although this might not work with complex subclasses of EIP712Type

Hmm.. Do you have any example this? What specifically are you suspicious won't work?

oh whoops, I didn't look at the context in the code

fubuloubu commented 3 years ago

@lost-theory please :+1: and then we can merge + release