mirror of https://github.com/embarklabs/embark.git
Framework for serverless Decentralized Applications using Ethereum, IPFS and other platforms
https://framework.embarklabs.io/
431d366652
If a transaction is sent and the proxy is enabled, but the function hash (identified in the data of the transaction) is not recognized as a function of the contract (ie does not match a function hash in the contract’s ABI), then embark would crash. The fix was to introduce error handling in `transactionUtils.getTransactionParams` that defaults the contract name and params to `UNKNOWN`. This can be replicated by 1. Clone https://github.com/mortimr/ethvtx_embark 2. `embark run` the dapp 3. Connect with Metamask 4. Ensure you have enough funds 5. In the “Tx calls” bubble, enter a new value, then click “Set Value”. 6. When the Metamask dialog appears, the error should have already happened. The console shows: ``` embark/src/lib/utils/transactionUtils.ts:58 const functionName = func.functionName; ^ TypeError: Cannot read property 'functionName' of undefined at functionName (/Users/mortimr/Horyus/ethvtx_embark/node_modules/embark/src/lib/utils/transactionUtils.ts:58:29) at ConsoleListener.getTransactionParams [as _onIpcLogRequest] (/Users/mortimr/Horyus/ethvtx_embark/node_modules/embark/src/lib/modules/console_listener/index.js:102:41) at _onIpcLogRequest (/Users/mortimr/Horyus/ethvtx_embark/node_modules/embark/src/lib/modules/console_listener/index.js:76:12) at Server._done (/Users/mortimr/Horyus/ethvtx_embark/node_modules/embark/src/lib/core/ipc.js:81:7) at Server.emit (/Users/mortimr/Horyus/ethvtx_embark/node_modules/event-pubsub/es5.js:74:21) at Server.gotData (/Users/mortimr/Horyus/ethvtx_embark/node_modules/node-ipc/dao/socketServer.js:194:14) at Socket.emit (events.js:189:13) at Socket.EventEmitter.emit (domain.js:441:20) at addChunk (_stream_readable.js:284:12) at readableAddChunk (_stream_readable.js:261:13) at Socket.Readable.push (_stream_readable.js:220:10) at Pipe.onStreamRead [as onread] (internal/stream_base_commons.js:94:17) ``` |
||
---|---|---|
.github | ||
dapps | ||
packages | ||
scripts | ||
.editorconfig | ||
.eslintrc.json | ||
.gitignore | ||
.npmrc | ||
.travis.yml | ||
.yarnrc | ||
CHANGELOG.md | ||
CODE_OF_CONDUCT.md | ||
CONTRIBUTING.md | ||
LICENSE | ||
README.md | ||
appveyor.yml | ||
babel.config.js | ||
header.png | ||
lerna.json | ||
package.json | ||
tsconfig.json | ||
tslint.json | ||
yarn.lock |
README.md
What is Embark
Embark is a framework that allows you to easily develop and deploy Decentralized Applications (DApps).
A Decentralized Application is a serverless html5 application that uses one or more decentralized technologies.
Embark currently integrates with EVM blockchains (Ethereum), Decentralized Storages (IPFS), and Decentralized communication platforms (Whisper and Orbit). Swarm is supported for deployment.
With Embark you can:
Blockchain (Ethereum)
- Automatically deploy contracts and make them available in your JS code. Embark watches for changes, and if you update a contract, Embark will automatically redeploy the contracts (if needed) and the dapp.
- Contracts are available in JS with Promises.
- Do Test Driven Development with Contracts using Javascript.
- Keep track of deployed contracts; deploy only when truly needed.
- Manage different chains (e.g testnet, private net, livenet)
- Easily manage complex systems of interdependent contracts.
Decentralized Storage (IPFS, Swarm)
- Easily Store & Retrieve Data on the DApp through EmbarkJS. Including uploading and retrieving files.
- Deploy the full application to IPFS or Swarm.
- Import and deploy contracts hosted on Swarm.
Decentralized Communication (Whisper, Orbit)
- Easily send/receive messages through channels in P2P through Whisper or Orbit.
Web Technologies
- Integrate with any web technology including React, Foundation, etc..
- Use any build pipeline or tool you wish, including grunt, gulp and webpack.
$ npm -g install embark