Upgrading on mainnet fails with error Transaction was not mined within 750 seconds

When upgrading an existing contract on the mainnet, it repeatedly fails, but the transaction fees keep getting deducted from my wallet.

Gasprice is set to just above average.
Upgrading works first try on ropsten.

Message:
? Pick a network mainnet

? Which instances would you like to upgrade? Choose by name

? Pick an instance to upgrade MultiSigFundWalletFactory

? Call a function on the instance after upgrading it? No

Nothing to compile, all contracts are up to date.

:heavy_multiplication_x: Validating and deploying contract MultiSigFundWalletFactory

MultiSigFundWalletFactory deployment failed with error: Transaction was not mined within 750 seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!

:computer: Environment

OpenZeppelin 2.8.2

:memo:Details

I dare not run it again (with verbose logging), as it’ll probably just fail and eat up all my funds :frowning:

:1234: Code to reproduce

1 Like

Hi @superkruger,

Welcome to the community :wave:

I’m sorry that you are having this issue.

When we upgrade, there are two transactions:

  1. Deploy the new implementation contract
  2. Update the proxy contract to point to the new implementation contract along with calling any function to initialize any new state.

We still have high gas prices (100+ on https://www.ethgasstation.info/).

I assume that your new implementation contract has been deployed. You could try manually updating your config mainnet.json based on a public testnet to add the new implementation contract address. I think oz upgrade will then pick up the new implementation address (though I would want to check this).

Hi @superkruger,

Just to confirm that oz upgrade will use the new implementation address (though you will need to manually set this up as the CLI timed out waiting for the transaction to be mined) to perform the upgrade.

Hi Andrew,

Thanks for the prompt response.
I’ve managed to upgrade all contracts eventually, but it feels like funds have been taken repeatedly.

I’ll keep your suggestion in mind for next time.

Perhaps it’s an idea to output the results and tx hash of each step along the way?

Cheers
Jaco

1 Like

Hi @superkruger,

Glad you were able to upgrade.

Thanks for the suggestion. I have created an issue: https://github.com/OpenZeppelin/openzeppelin-sdk/issues/1577

We just released Truffle Upgrades and Buidler Upgrades plugins, both of which should pickup where you left off when deploying and upgrading.

See the following for details: