Issues testing the ckbtc_minter code for the main network

I’m having issues trying to deploy my own ckbtc_minter on the main network.
My operation process is as follows:

  1. Calling get_btc_address() to get address.
  2. Transfer btc to the address.
  3. Calling update_balance() and receive UpdateBalanceResult(amount&block_index).
  4. Check my ckbtc_token balance and get the correct amount.

But when I try to ckbtc → btc, I have a issue

  1. Calling get_withdrawal_account() to get account.
  2. Transfer ckbtc to the account.
  3. Calling retrieve_btc to get block_index.
  4. Calling retrieve_btc_status() with block_index keeps alternating between returning “pending” and “singing”

Does anyone know why this result keeps coming up, about 3 hours have passed?

ckbtc_minter InitArgs:

record {
	btc_network=variant { Mainnet };
	ledger_id=principal "<ckbtc_token canister id>";

Just to make sure that it’s clear: ckBTC is still under development, so there is no guarantee that things work end-to-end.

I don’t know what’s causing the behavior you’re seeing.
Of course, you are free to experiment with the existing code but it might be easier to wait until the ckBTC launch, at which point the code will definitely be stable and well-tested.

1 Like

You are trying to retrieve “retrieve_btc_min_amount=2” which is 2 Satoshis. This can be the source of your problem. Because if the amount you are trying to retrieve is lower than the fee you have to pay it won’t send the tx to the BTC network.
Which arguments did you use to initialise the minter canister ?

note : ckBTC is still under development

1 Like

One reason for such behavior could be a failure to obtain an ECDSA signature or submit a Bitcoin transaction. The insufficient cycle balance of the minter can cause such a failure, for example. How many cycles does your minter have?