Closed ekkis closed 7 months ago
incidentally, if I change the address of the contract to use that of the token manager contract, I get the same effect -- no tokens minted. here's the output from the transaction:
{"_type":"TransactionResponse","accessList":[],"blockNumber":1,"blockHash":"0xe22945792cb2f4314f04c63e7aaee5402690820d662e4ca4413b067222a509f8","blobVersionedHashes":null,"chainId":"31337","data":"0x40c10f19000000000000000000000000d5070f2a2c706c086407ac8f3bd4f21e3e46cb9900000000000000000000000000000000000000000000000000000000000007d0","from":"0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266","gasLimit":"30000000","gasPrice":"1875000000","hash":"0xe6beeb1042545565d18091b558e0c8c5cd3e552488295ac3598743d1f891c8e1","maxFeePerGas":"2750000000","maxPriorityFeePerGas":"1000000000","maxFeePerBlobGas":null,"nonce":0,"signature":{"_type":"signature","networkV":null,"r":"0xd1afba03fa9237aaaab4d96d8440833449d6485056d317fbcf404bcab49e3439","s":"0x7fd41090fa2b3334fcbb21f1f367d9efdb5027c088746be619138bfa34330cce","v":27},"to":"0xB86E556574B5bf2A4e3E328Ecbb9EAc8e6F0Ce8E","type":2,"value":"0"}
so what I don't understand is: how does this code know which account is signing the transaction? it needs to have access to a private key to do it and I haven't provided one. I get the sense that hre.ethers.getSigners()
is a list of Axelar approved keys but if I'm generating the transaction, I need to sign it and my code doesn't provide that. so what am I missing?
ok. I figured out the problem. I was following this guide: https://docs.axelar.dev/dev/send-tokens/interchain-tokens/developer-guides/programmatically-create-a-token, which declares a hardhat.config.js
without a default network. when adding defaultNetwork: "fantom"
, it allowed broadcasting of transactions. it all works now
That's a great news. Thanks for the feedback.
I'm building a proof-of-concept whereby I've created a token using the portal (which may be found here: https://testnet.interchain.axelar.dev/fantom/0xDEdbd54Ffc534a1aEC6D290E7FC5a337218D2708) and minted some tokens to my account
now I'm trying to do it using the API and here's what' I've cobbled together:
...which, when run, produces this:
...however, I never receive the tokens. as can be seen from the above, there is a transaction hash generated but then I look it up on AxelarScan it doesn't find it (see: https://testnet.axelarscan.io/gmp/0xb437d1a075f998664445d010241bb8e14f527ca62636a3b5f39e5f46c76799e8). it also doesn't find it on FantomScan (I'm not entirely sure where to look): https://testnet.ftmscan.com/tx/0xb437d1a075f998664445d010241bb8e14f527ca62636a3b5f39e5f46c76799e8
so I gather the transaction is not being broadcast. am I missing something in the code,. or is there some configuration thing I'm missing?
the address I'm sending to received the tokens I minted through the portal but never receives the ones issued by the code
thanks in advance
-- ekkis