To Update to 2.6.0
Embark’s npm package has changed from
embark, this sometimes can create conflicts. To update, first uninstall embark-framework 1 to avoid any conflicts with
npm uninstall -g embark-framework followed by
npm install -g embark
to update from 2.5.2:
npm install -g [email protected]
afterwards make sure
embark version returns
In this release
You no longer need to wait for new releases of embark when a new version of web3.js or solc comes out as this can be now configured. Embark will take care of downloading and using the new versions. You can specify a list of nodes the dapp should attempt to connect to (instead of being limited 1). Whisper 5 is now supported.
Support for web3.js 1.0 and (nearly) ANY web3.js version
Embark now supports web3.js 1.0 by default, however you can now also specify exactly which version of web3.js you want to use so you can still use 0.19.0 or newer versions of 1.0.
If ,for example, you wish to use 0.19.0 you can specify it in the config as
Support for ANY solc version
You can also configure the solc compiler you wish to use and it should work, so long that solc release does not contain breaking API changes.
Specify nodes DApp should attempt to connect to
You can specify which nodes your dapp should try to connect in each enviroment. “$WEB3” is a special keyword to specify the existing web3 object.
The following config would attempt to use the existing web3 object and if unavailable attempt to connect to localhost:8545
Specify node to deploy to
Before Embark would assume this would be the same as the one configured in blockchain.json which could lead to some ackward configs for some devs, this has now been changed so you can specify it in the contracts config.
Specify node to connect whisper to
Specify url to get assets
You can specify for each environment what IPFS node to get the assets from
Plugin API changes
The following events are deprecated: abi-vanila, abi, abi-contracts-vanila, abi-vanila-deployment and have been renamed to code-vanila, code, code-contracts-vanila, code-vanila-deployment
plugins that use these events will get deprecation warnings, the deprecated events will be removed in 2.7.0
New Blockchain options
The following fields are now available at
config/blockchain.json to enhance
- “wsHost” - to specify the websocket host (default: localhost)
- “wsPort” - to specify the websocket port (default: 8546)
- “wsOrigins”- to specify the allowed origin of the websocket requests (default: FALSE), must be specified to something like http://localhost:8000 for the websocket connection to work.
- “wsApi” - to specify the apis available through websockets (default: [‘eth’, ‘web3’, ‘net’, ‘shh’])
Misc Bugfixes and Improvements
- tests no longer need the requires and initialization and can be run directly with embark. however you can still use these requires to run it yourself with mocha or your own preferred test framework
- embark and mocha are no longer dependencies in the created dapp
- you can specify a test file with
embark test <filename>
- tests no longer need testrpc to be installed first
EmbarkJS.isNewWeb3()to detect if web3 1.0 is available
- demo app updated to use web3.js 1.0 and solc 0.4.17
- warn user when websocket or http CORS is not set
- tolerate solc compiler warnings, which could cause a crash sometimes
A big thanks to all that contributed to this release including Todd Baur and Jacob Beauchamp.
To discuss about Embark or Dapp development, please join us at the gitter channel