Open
Description
This would reduce friction for test implementers unfamiliar with the EEST codebase.
Here's an example: If a Storage
object is defined in test cases, mypy
fails to detect that int
is a valid type as a dict key or value. Currently, such Storage
definitions need to be either marked as type:ingore
or expliclitly cast to HashInt
, e.g. Storage(cast(Storage.StorageDictType, {1,1}))
.
Here, for example, type checking is manually disabled inline:
Otherwise, mypy
returns the following two errors:
tests/cancun/eip4788_beacon_root/spec.py:61: error: Key expression in dictionary comprehension has incompatible type "int"; expected type "HashInt" [misc]
tests/cancun/eip4788_beacon_root/spec.py:61: error: Value expression in dictionary comprehension has incompatible type "int"; expected type "HashInt" [misc]