307 Commits

Author SHA1 Message Date
Jonathan Rainville
01900f8c6e wip fixes 2018-08-21 15:26:31 -04:00
Jonathan Rainville
0e973dd908 conflict in provider 2018-08-21 15:22:07 -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
Jonathan Rainville
5a3a9878f9 add triple equals 2018-08-21 15:03:34 -04:00
Jonathan Rainville
86d8a30c15 fix tests using new dependencies 2018-08-21 15:03:34 -04:00
Jonathan Rainville
3c952f89ed make groups of dependencyCount to do async by group 2018-08-21 15:03:34 -04:00
Jonathan Rainville
7abdc9e0e6 set a limit funding 2018-08-14 14:05:21 -04:00
Iuri Matias
a01e600857
Merge pull request #627 from embark-framework/bug_fix/warning-contract-path
trim the contract name to have the warning correctly (patch)
2018-07-26 13:31:59 -04: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
91f1748d60 don't wait for account funds 2018-07-17 17:30:23 +03:00
Iuri Matias
231199c0dc ad missing emit 2018-07-17 16:13:12 +03:00
Iuri Matias
d0162a6c78 move - for now - determining gas price to deployment to avoid race conditions 2018-07-17 15:10:22 +03: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
Jonathan Rainville
8875b1b7ab trim the contract name to have the warning correctly 2018-07-12 12:36:54 -04:00
Iuri Matias
6ee387653d fix metamask check for non dev environment 2018-06-29 18:14:21 -04:00
Iuri Matias
db3356cec0 detect if there is a connection error and pass it down to the ready function 2018-06-29 18:14:08 -04:00
Jonathan Rainville
aa02aeb74c move pingEndpoint to utils 2018-06-19 09:02:19 -04:00
emizzle
ba66d763fe Add support for infura network hosts with api key.
Fix bug with non-development code generation.
2018-06-19 15:14:37 +10:00
emizzle
b56def7c57 Updated web3 endpoint for use with infura api key and https
Allows `protocol` to be specified in config/contract.js[on] for `<env>/deployment/protocol`.
2018-06-19 14:43:55 +10:00
Jonathan Rainville
ed1ac3af2e register web3 after init 2018-06-18 14:33:25 -04:00
Jonathan Rainville
a988962aed change package name 2018-06-18 09:26:17 -04:00
Iuri Matias
37ab60d6de
Merge pull request #538 from embark-framework/features/ws-node
Enable connection to websocket node
2018-06-15 18:01:12 -04:00
emizzle
15faf3a336 Fix for starting embark with a contract that has an error, then fixing, seems to still break the pipeline.
Needed to reset the `compileError` flag once compilation succeeded.
2018-06-15 17:31:17 -04:00
Jonathan Rainville
eb0ccbe7cc remove useless param 2018-06-15 15:22:06 -04:00
Jonathan Rainville
f32ac90e71 enable connecting to ws node in tests 2018-06-15 15:16:55 -04:00
Jonathan Rainville
c8c0a5c42f enable websocket provider 2018-06-15 14:35:50 -04:00
Jonathan Rainville
dcbd868b78 get gasPrice if no gasPrice set in contract.json 2018-06-14 15:22:50 -04:00
Iuri Matias
a48a05cd27 remove unnended event listeners 2018-06-14 11:03:06 -04:00
Iuri Matias
5a2cf62ee5 reload config; create a config so it doens't damage original 2018-06-14 09:22:13 -04:00
Jonathan Rainville
8766c9b761 show warning if dependency is not deploying 2018-06-13 13:47:11 -04:00
Iuri Matias
c8b52a1746 fix errors handling so it doesn't attempt to continue building when there are fatal errors compiling contracts 2018-06-08 07:07:27 -04:00
Jonathan Rainville
a6a5bac053 use new provider when using account with a node specified 2018-06-07 16:07:58 -04:00
Jonathan Rainville
1b89199f50 fund accounts in wallet using contracts config 2018-06-07 13:06:09 -04:00
Jonathan Rainville
a5ecd9f1f4 add tests for getBalance 2018-06-07 13:01:13 -04:00
Jonathan Rainville
bb3e87d85e move getBalance in accountParser 2018-06-07 13:01:12 -04:00
Jonathan Rainville
ac631f90dc fix missing error callback 2018-06-07 13:01:12 -04:00
Jonathan Rainville
bfc8663a61 change account funding order to enable starting a node before 2018-06-07 12:55:07 -04:00
Iuri Matias
cd6dcb7548 fix setting default account 2018-06-06 10:39:02 -04:00
Jonathan Rainville
b32c90b56e compile tests only once 2018-06-04 10:45:50 -04:00
Iuri Matias
37d54e22db refactor services monitor to use events instead of passing addCheck around 2018-06-01 19:32:14 -04:00
Iuri Matias
17f5bb3905
Merge branch 'develop' into features/test-revamp-multi 2018-06-01 18:14:32 -04:00
Jonathan Rainville
876a9a3103 fix pipeline not building by removing the onces 2018-06-01 15:48:10 -04:00
Jonathan Rainville
b727d85358 small fixes 2018-06-01 13:53:09 -04:00
Jonathan Rainville
2d1a37d63b conflict in pakcgae lock 2018-06-01 13:44:49 -04:00
Jonathan Rainville
8664570d7c conflict in test 2018-06-01 13:43:43 -04:00