eattheblocks
eattheblocks copied to clipboard
error when tried to connect to infura blockchain LESSON 12
Hi i encountered the below issue, please advise how to solve this
Error: connection not open on send()
at Object.ConnectionError (C:\Users\anthony\Downloads\Flashloan\node_modules\web3-core-helpers\lib\errors.js:66:23)
at Object.ConnectionNotOpenError (C:\Users\anthony\Downloads\Flashloan\node_modules\web3-core-helpers\lib\errors.js:49:21)
at C:\Users\anthony\Downloads\Flashloan\node_modules\web3-providers-ws\lib\index.js:155:37
at Map.forEach (
First install @hdwallet module and store your mnemonic of wallet in env file also install env module and then create your network like i am creating ropsten here
:=
ropsten: {
provider: () => new HDWalletProvider(Process.env.KEY, https://ropsten.infura.io/v3/${Process.env.PROJECTID}
),
network_id: 3, // Ropsten's id
gas: 5500000, // Ropsten has a lower block limit than mainnet
confirmations: 2, // # of confs to wait between deployments. (default: 0)
timeoutBlocks: 200, // # of blocks before a deployment times out (minimum/default: 50)
skipDryRun: true // Skip dry run before migrations? (default: false for public nets )
},
then Run command npx truffle network --ropsten