zeta-chain/example-contracts

Unstake task does not work as should.

Closed this issue · 1 comments

Issue with unstake.ts Task in Hardhat Project

File Location

template/tasks/unstake.ts

Problem Description

The unstake.ts task within the Hardhat project is not functioning as intended based on the guidelines in the official documentation. This issue is observed specifically when the deployer wallet attempts to unstake tokens after setting both the beneficiary and withdraw addresses.

Current Behavior

  • When executing the unstake task, it results in an outgoing transaction from the signer (msg.sender) to the deployed contract.
  • If the value field of the transaction is populated with a certain amount of Ether, this Ether is inadvertently sent to the contract.

Undesired Outcome

  • The current behavior of sending Ether to the contract during the unstake process is not the intended functionality.
  • The expected behavior is for the unstake operation to proceed without transferring Ether from the signer to the contract.

NB: Just got clarification from the team that for some reasons cctx can't be read on goerli and mumbai testnet at the moment. Apparently this was the cause.