TransactionSEALED
╲▓▒╲#□●*■$○■^▫▫◇▫%█&╳╳░▒▫╳█?@░▓?%╳░░&%○▪▓^*?■~^●&~◆▓▒●╲╳○□~█▫#%▓
Transaction ID
Execution Error
Error Code: 1009
error caused by: 1 error occurred:
Raw Error
[Error Code: 1009] error caused by: 1 error occurred: * transaction verification failed: [Error Code: 1006] invalid proposal key: public key 6 on account f380b22ef386ac7e does not have a valid signature: [Error Code: 1009] invalid envelope key: public key 6 on account f380b22ef386ac7e does not have a valid signature: signature is not valid
Transaction Summary
TransactionScript Arguments
0recipientEVMAddressHexString
1amountUFix64
0.00100000
2gasLimitUInt64
16777216
Cadence Script
1import FungibleToken from 0xf233dcee88fe0abe
2import FlowToken from 0x1654653399040a61
3import EVM from 0xe467b9dd11fa00df
4
5/// Transfers $FLOW from the signer's account Cadence Flow balance to the recipient's hex-encoded EVM address.
6/// Note that a COA must have a $FLOW balance in EVM before transferring value to another EVM address.
7///
8transaction(recipientEVMAddressHex: String, amount: UFix64, gasLimit: UInt64) {
9
10 let coa: auth(EVM.Withdraw, EVM.Call) &EVM.CadenceOwnedAccount
11 let recipientEVMAddress: EVM.EVMAddress
12 var sentVault: @FlowToken.Vault
13
14 prepare(signer: auth(BorrowValue, SaveValue) &Account) {
15 if signer.storage.type(at: /storage/evm) == nil {
16 signer.storage.save(<-EVM.createCadenceOwnedAccount(), to: /storage/evm)
17 }
18 self.coa = signer.storage.borrow<auth(EVM.Withdraw, EVM.Call) &EVM.CadenceOwnedAccount>(from: /storage/evm)
19 ?? panic("Could not borrow reference to the signer's bridged account")
20
21 let vaultRef = signer.storage.borrow<auth(FungibleToken.Withdraw) &FlowToken.Vault>(
22 from: /storage/flowTokenVault
23 ) ?? panic("Could not borrow reference to the owner's Vault!")
24 self.sentVault <- vaultRef.withdraw(amount: amount) as! @FlowToken.Vault
25
26 self.recipientEVMAddress = EVM.addressFromString(recipientEVMAddressHex)
27 }
28
29 execute {
30 self.coa.deposit(from: <-self.sentVault)
31
32 let valueBalance = EVM.Balance(attoflow: 0)
33 valueBalance.setFLOW(flow: amount)
34 let txResult = self.coa.call(
35 to: self.recipientEVMAddress,
36 data: [],
37 gasLimit: gasLimit,
38 value: valueBalance
39 )
40 assert(
41 txResult.status == EVM.Status.failed || txResult.status == EVM.Status.successful,
42 message: "evm_error=".concat(txResult.errorMessage)
43 )
44
45 }
46}