Commit Graph

155 Commits

Author SHA1 Message Date
Jonathan Rainville 3e65d1c11b add geth miner. Needs to change eth and web3 2018-08-21 15:18:12 -04:00
Jonathan Rainville 1970f8fc53 use right path depending of os 2018-08-21 15:18:12 -04:00
Jonathan Rainville 5581964fab conflict in package json 2018-08-21 15:17:05 -04:00
emizzle bcd5593040 Updated online/offline event checks so they are run during initialisation.
Changed the online event to `once` and set it to be bound every time the node goes offline.

The above changes handle the case where:
1) `embark run` runs and starts geth.
2) geth is killed manually
3) `embark blockchain` is run in separate process to restart geth
4) the `embark run` process detects this change and restarts the web3 provider and recompiles/deploys/builds

Every time `embark blochain` is restarted, an error is appended and all are emitted from the `eth-block-tracker`. This is a bug but can't figure out where it originates. The downside is that if, for example, `embark blockchain` is restarted 4 times, there will be 4 errors emitted from the `eth-block-tracker`. Because of this, errors emitted from `eth-block-tracker` have been reduced to trace to avoid clogging the logs.
2018-08-21 15:08:25 -04:00
emizzle ee59d43c77 Handle geth process exit via crash/kill and also via killing `embark blockchain`
First case - run `embark run` which starts a blockchain node, then manually kill the `geth` process. Would throw `{ [Error: connect ECONNREFUSED 127.0.0.1:8543] message: 'connect ECONNREFUSED 127.0.0.1:8543', code: -32603 }` error and ruins the dashboard.

Second case, 1) run `embark blockchain` 2) run `embark run` 3) kill `embark blockchain` throws the error `{ [Error: connect ECONNREFUSED 127.0.0.1:8543] message: 'connect ECONNREFUSED 127.0.0.1:8543', code: -32603 }` and ruins the dashboard.

The first case was solved by having the child blockchain process that spawns geth listen for geth exit, then kill itself.

The second case required updating of `eth-block-tracker` to v4.0.1 inside of the `embark-web3-provider-engine`. v4.0.1 was a major version update and introduced breaking changes. Those changes were handled inside of `embark-web3-provider-engine`, covered in **blocker** PR https://github.com/jrainville/provider-engine/pull/1.
2018-08-21 15:08:25 -04:00
Richard Ramos 6a20458032 Fix for skip-undeployed is not specified 2018-08-21 15:03:34 -04:00
Michael Bradley, Jr a8f8acb7ff when installing template mv dot.gitignore -> .gitignore if it exists 2018-08-12 15:02:03 -05:00
Michael Bradley, Jr d70264adb6 blockchain -- defaultHost, dockerHostSwap 2018-08-02 15:31:55 -05:00
Michael Bradley, Jr 2ad8097dcb simulator -- defaultHost, dockerHostSwap 2018-08-02 15:31:27 -05:00
emizzle 9b41fa8ac2 Modified DevFunds to “factory pattern”
Added a “factory pattern” to DevFunds to allow for async calls to be made during object construction. This allows for `web3.eth.getAccounts` to be called and the `accounts` property assigned on instantiation.

This modification allows each unit test case to be run independently of the others.
2018-08-01 11:35:42 +10:00
emizzle 7cb9cd5622 Basic unit tests complete for dev funds
Finished added unit tests for dev_funds. These are weak tests as the FakeIpcProvider does not provide enough support for keeping track of accounts and balances and instead we are injecting the provider responses in the tests, which kind of defeats the purposes of the tests. Instead, the FakeIpcProvider should be a little smarter and do more of what a real node would do.
2018-07-31 14:59:55 +10:00
emizzle 12304eac16 Adding in unit tests for dev_funds (WIP) 2018-07-31 14:59:55 +10:00
Iuri Matias c44a95e6ea fix linting issue 2018-07-30 06:58:54 -04:00
Iuri Matias 71e9eed67b use config password file; tolerate somethign going terribly wrong since it wouldnt' affect the blockchain process generally 2018-07-19 11:15:16 +03:00
Iuri Matias 69f356b3f0 only use personal in --dev mode 2018-07-19 10:58:47 +03:00
Iuri Matias 0099078e94 fix lint 2018-07-18 17:53:37 +03:00
Iuri Matias c1809e3752 Merge branch 'fund_accounts' of github.com:embark-framework/embark into fund_accounts 2018-07-18 17:48:58 +03:00
Iuri Matias 20406ba51a fix lint 2018-07-18 17:47:53 +03:00
emizzle 9382f98933 Housekeeping and removal of none additions
Clean up debugging statements from fund_accounts.

Removed the addition of the nonce increment for contracts deploy as this was only affecting mneumonic-generated accounts which is not meant for dev environment.
2018-07-18 14:08:32 +02:00
Iuri Matias 5e3740f088 add regular account unlocks in devMod due to issues with geth 2018-07-18 13:45:18 +03:00
Iuri Matias 28dd6dba60 add interval to send txs to deal with geth --dev bug 2018-07-18 13:29:02 +03:00
Iuri Matias 3d1db2b21e Merge branch 'fund_accounts' of github.com:embark-framework/embark into fund_accounts 2018-07-17 17:49:32 +03:00
Iuri Matias 91f1748d60 don't wait for account funds 2018-07-17 17:30:23 +03:00
emizzle 7e12c5a9f7 funding dev account updates
Now funds accounts only if they have not been funded, and also funds with only the amount needed.

Also fixed bug with unlocking accounts when re-running `unlockAccounts` on already created accounts.
2018-07-17 10:57:31 +02:00
emizzle 296663edc7 password read from config file and fix for gasprice 2018-07-16 21:19:01 +02:00
emizzle 11d6980f70 further dev funding 2018-07-16 18:48:32 +02:00
Iuri Matias f2213970f7 first stab at funding accounts in geth given config 2018-07-13 15:56:59 +03:00
Jonathan Rainville da01ab15db enable using both syncMode and syncmode 2018-07-06 09:31:28 -04:00
Iuri Matias 289be4b8a4 check for cmd not found in stderr 2018-07-04 16:40:46 +03:00
Iuri Matias a7a6a62edc make linter happy 2018-07-04 16:36:49 +03:00
Iuri Matias 6c03a2e212 ignore stderr since geth outputs normal logs to it 2018-07-04 16:10:12 +03:00
Jonathan Rainville 5ac45f18b0 fix account initialization and address use 2018-07-03 15:10:44 -04:00
Jonathan Rainville ffb3ec544b fix account initialization and address use 2018-07-03 14:55:04 -04:00
Iuri Matias 589589cb6a don't use -h option due to bug in ethersim fork v2 2018-06-25 12:48:35 -04:00
Iuri Matias 76ab330546 add debug option 2018-06-18 09:44:16 -04:00
Jonathan Rainville d77083ee8c enable syncMode 2018-06-15 16:33:59 -04:00
VoR0220 391777d5bf fix test app config and swap olympic for rinkeby as testnet option
Signed-off-by: VoR0220 <catalanor0220@gmail.com>
2018-06-15 13:18:37 -05:00
Jonathan Rainville a09f680ca7 fix testnet and olympic network types 2018-06-14 15:22:01 -04:00
Iuri Matias be6ada2909 remove old instructions 2018-06-14 09:22:13 -04:00
Iuri Matias e0ff5b3580 remove anoying backtrace 2018-06-12 13:58:21 -04:00
Iuri Matias 5b1eeab7ed make debug a default api option 2018-06-12 12:21:46 -04:00
Richard Ramos 9e92069667 Fixing conflicts 2018-06-11 16:44:34 -04:00
Richard Ramos 38e6a9571d Updating tests 2018-06-11 16:43:26 -04:00
Richard Ramos 48a3f2afdc Fixing conflicts 2018-06-11 16:43:08 -04:00
Iuri Matias a4985fde40 make proxy mode the default 2018-06-11 16:40:59 -04:00
Richard Ramos 6040509942 Adding line break 2018-06-11 16:40:59 -04:00
Richard Ramos 0f853ba841 Typo 2018-06-11 16:40:59 -04:00
Richard Ramos c1621c4029 Websocket support 2018-06-11 16:40:59 -04:00
Richard Ramos bf25381fa6 Rebasing changes from develop 2018-06-11 16:40:14 -04:00
Richard Ramos 05f5a145f1 Added proxy to blockchain 2018-06-11 16:38:29 -04:00