@classmethod
def deserialize_hex(cls, raw: str) ->'EthTx':
    """Serialize a transaction from hex."""
    r = raw
    if r[:2] == '0x':
        r = r[2:]
    return cls.deserialize(bytes.fromhex(r))
