From 5e3740f088eff63b3a26d15c2321df5c491ad454 Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Wed, 18 Jul 2018 13:45:18 +0300 Subject: [PATCH] add regular account unlocks in devMod due to issues with geth --- lib/cmds/blockchain/dev_funds.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/cmds/blockchain/dev_funds.js b/lib/cmds/blockchain/dev_funds.js index 55217c390..09f6b3efa 100644 --- a/lib/cmds/blockchain/dev_funds.js +++ b/lib/cmds/blockchain/dev_funds.js @@ -43,6 +43,11 @@ class DevFunds { }); } + regularUnlocks() { + const self = this; + setInterval(function() { self.unlockAccounts(self.password, () => {}) }, 20000); + } + connectToNode(cb) { this.web3.setProvider(new Web3.providers.WebsocketProvider(buildUrl('ws', this.blockchainConfig.wsHost, this.blockchainConfig.wsPort), { headers: { Origin: "http://localhost:8000" } })); @@ -126,6 +131,7 @@ class DevFunds { (next) => { console.dir('--- FUNDING THE ACCOUNTS'); this.regularTxs(); + this.regularUnlocks(); this.fundAccounts(this.balance, next); } ], (err) => {