Open
Description
Describe the bug
PlutusData
classes honor old type hints (e.g. List[bytes]
) by using issubclass
.
Modern type hints (e.g. list[bytes]
) fail because list
is not a class.
This is the guilty line of code:
Line 533 in fdff5f2
To Reproduce
Create a PlutusData
class with modern type hints and try to instantiate.
from pycardano import PlutusData
class Test(PlutusData):
a: list[bytes]
Test(a=[b'hello', b'world'])
Environment and software version (please complete the following information):
- PyCardano Version 0.10.0