question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

truffle migrate does a "--dry-run" by default. Can't deploy on network

See original GitHub issue

I can’t deploy on network anymore because dry-run is used by drefault. --skip-dry-run doesn’t help.

Command I use:

truffle migrate --reset --network=sokol

Result I got:

Migrations dry-run (simulation)
===============================
> Network name:    'sokol-fork'
> Network id:      77
> Block gas limit: 0x7a1200

Config:

module.exports = {
    contracts_build_directory: process.cwd() + "/build/eth",
    compilers: {
        solc: {
            version: "0.4.25"
        }
    },
    solc: {
        optimizer: {
            enabled: true,
            runs: 200
        }
    },
    networks: {
...
        sokol: {
            provider: () =>  new HDWalletProvider(accounts[accountName].key, "https://sokol.poa.network/"),
            network_id: '77',
            gas: 75e5,
            gasPrice: gasPrice || 1e9
        },
...
  • Operating System: windows Truffle v5.0.13 (core: 5.0.13) Solidity - 0.4.25 (solc-js) Node v8.12.0 Web3.js v1.0.0-beta.37

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

8reactions
eggplantzzzcommented, Apr 18, 2019

@mscherer82 Hey, yes this is a bug that we should have fixed in the next release. If you’d like to skip the dry run for now, you can add skipDryRun: true in your network config under sokol. That should skip it for you and should continue to run in the future. With the next release you should be able to use both skip-dry-run(--skip-dry-run as a command line option) and skipDryRun (--skipDryRun on the command line) in the config to skip the dry run.

1reaction
CruzMolinacommented, Apr 27, 2019

@mscherer82 What version of truffle-hdwallet-provider are you using? 1.0.7 has a bug in it that breaks migrations. 1.0.6 & 1.0.8 currently don’t have any known issues.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Strange output from truffle migrate --network live --dry-run
I can't get my contract to deploy successfully using Infura, MetaMask, and Truffle. When I run truffle migrate --network live I get this...
Read more >
Solidity migrate contract dry run vs for real - Stack Overflow
I just deployed my crowdsale and that seems to succeed. However truffle is not showing me a contract address which is worrying. I...
Read more >
Configuration - Truffle Suite
Specifies which networks are available for deployment during migrations, as well as specific transaction parameters when interacting with each network (such as ...
Read more >
fork' to networkName when migrating to rinkeby - SDK
Truffle is performing a dry run simulation when you do npx truffle migrate --network rinkeby . Your ropsten network configuration has skipDryRun ......
Read more >
Deploy a Smart Contract Using Truffle - Polygon Wiki
What you will do​ · Install and set up Truffle · Deploy contract on Polygon Network · Check the deployment status on Polygonscan ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found