def as_signed_transaction(self, private_key, chain_id=None): v, r, s = create_transaction_signature(self, private_key, chain_id=chain_id) return ConstantinopleTransaction( nonce=self.nonce, gas_price=self.gas_price, gas=self.gas, to=self.to, value=self.value, data=self.data, v=v, r=r, s=s, )
def as_signed_transaction(self, private_key): v, r, s = create_transaction_signature(self, private_key) return HomesteadTransaction( nonce=self.nonce, gas_price=self.gas_price, gas=self.gas, to=self.to, value=self.value, data=self.data, v=v, r=r, s=s, )
def as_signed_transaction(self, private_key: PrivateKey) -> FrontierTransaction: v, r, s = create_transaction_signature(self, private_key) return FrontierTransaction( nonce=self.nonce, gas_price=self.gas_price, gas=self.gas, to=self.to, value=self.value, data=self.data, v=v, r=r, s=s, )
def as_signed_transaction(self, private_key: PrivateKey, chain_id: int = None) -> ByzantiumTransaction: v, r, s = create_transaction_signature(self, private_key, chain_id=chain_id) return ByzantiumTransaction( nonce=self.nonce, gas_price=self.gas_price, gas=self.gas, to=self.to, value=self.value, data=self.data, v=v, r=r, s=s, )