#Disclamer: this tut is not yet completed, I'm writting at the time I'm making several tests and learning on how to use the Aragon code
Notes on setting up your dev tools for running the basic aragon sample. The idea is helping to build a basic guide tutorial for newbies. Please note that these notes are in continuous review.
For this tutorial I'm using npm 9.2.0
2- [git] (https://git-scm.com/)
git clone https://github.com/aragon/aragon-core
//Aragon-core repo - not sure if needed
git clone https://github.com/aragon/apm-contracts
//apm-contracts repo
git clone https://github.com/aragon/aragon-example-application
//sample repo
npm install -g git+https://github.com/aragon/aragon-dev-cli.git
//cli tool needed for the sample
npm install
ON-GOING
npm install
ON-GOING
npm install
ON-GOING
a) Truffle versioning problem. Error: $LOCALWORKSPACE/apm-contracts/node_modules/ethereumjs-testrpc/build/lib.node.js:58296 var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null) [...] abort(5) at Error
Upgrading truffle to the system version (in package.json ) seems to solve the problem. In case you have truffle 4.0.1, change "truffle": "^3.2.5"
to "truffle": "^4.0.1"
if you have some issues with solc compiler go to issue c)
Or try to uninstall your current truffle system version:
npm uninstall truffle
b) (apm-contracts) In prepublish script I've got the error: & compile 16227 info lifecycle @aragon/[email protected]~prepublish: Failed to exec prepublish script
It seems that there is some problems trying to adding new paths into my local $PATH system env variable. I've added it manually (.bashrc):
export PATH="$HOME/.nvm/versions/node/v9.2.0/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:$LOCALWORKSPACE/apm-contracts/node_modules/.bin:$PATH"
Then update the env with
source ~/.bashrc
c) Solidity compiler version: SyntaxError: Source file requires different compiler version (current compiler is 0.4.18 [...] Follow the solution at https://ethereum.stackexchange.com/questions/17551/how-to-upgrade-solidity-compiler-in-truffle/26485#26485
I've just modified the following contracts: (aragon-core) $LOCALWORKSPACE/aragon-core/contracts/kernel/IKernel.sol $LOCALWORKSPACE/aragon-core/contracts/apps/AppStorage.sol:1:1: $LOCALWORKSPACE/aragon-core/contracts/apps/App.sol $LOCALWORKSPACE/aragon-core/contracts/common/DelegateProxy.sol $LOCALWORKSPACE/aragon-core/contracts/apps/AppProxy.sol $LOCALWORKSPACE/aragon-core/contracts/common/EVMCallScript $LOCALWORKSPACE/aragon-core/contracts/common/erc677/ERC677Receiver.sol $LOCALWORKSPACE/aragon-core/contracts/common/erc677/ERC677Token.sol $LOCALWORKSPACE/aragon-core/contracts/common/EtherToken.sol $LOCALWORKSPACE/aragon-core/contracts/common/IForwarder.sol $LOCALWORKSPACE/aragon-core/contracts/common/Initializable.sol $LOCALWORKSPACE/aragon-core/contracts/common/TokenController.sol $LOCALWORKSPACE/aragon-core/contracts/kernel/KernelStorage.sol $LOCALWORKSPACE/aragon-core/contracts/kernel/Kernel.sol $LOCALWORKSPACE/aragon-core/contracts/kernel/KernelProxy.sol
(apm-contracts) $LOCALWORKSPACE/apm-contracts/node_modules/@aragon/core/contracts/common/DelegateProxy.sol
(aragon-example-application) $LOCALWORKSPACE/aragon-example-application/node_modules/@aragon/core/contracts/kernel/IKernel.sol $LOCALWORKSPACE/aragon-example-application/node_modules/@aragon/core/contracts/apps/AppStorage.sol $LOCALWORKSPACE/aragon-example-application/node_modules/@aragon/core/contracts/apps/App.sol
adding a ^
in the solidity compiler version, i.e pragma solidity ^0.4.15;
aragon-dev-cli init poll.aragonpm.eth
cd poll
npm i truffle -g
//install truffle
npm run build
a) Solc version
$LOCALWORKSPACE/poll/node_modules/@aragon/core/contracts/kernel/IKernel.sol
$LOCALWORKSPACE/poll/node_modules/@aragon/core/contracts/apps/AppStorage.sol
$LOCALWORKSPACE/poll/node_modules/@aragon/core/contracts/apps/App.sol
$LOCALWORKSPACE/poll/node_modules/@aragon/core/contracts/common/Initializable.sol:
a) Import libs path In App.sol import "../node_modules/@aragon/core/contracts/apps/App.sol"; import "../node_modules/@aragon/core/contracts/common/Initializable.sol";
Notes: I appreciate any help on improving this basic tutorial on Aragon