Commit Graph
100 Commits
Author SHA1 Message Date
bumiandGitHub 5820d71b2c Merge pull request #96 from 67P/feature/pagination
Add pagination for .all methods
2019-04-17 13:53:17 +00:00
bumiandGitHub 4771c0c8a0 Merge branch 'master' into feature/pagination 2019-04-17 13:52:53 +00:00
bumiandGitHub 8abc7ba77f Merge pull request #104 from 67P/chore/update-kosmos-schema
Update kosmos-schema dependency
2019-04-16 11:19:03 +00:00
bumi f696721918 Readme: add note about locally running out of funds 2019-04-16 13:17:54 +02:00
bumi 00b58dec66 Update kosmos-schema dependency 2019-04-16 13:16:05 +02:00
bumiandGitHub 560315cbca Merge pull request #102 from 67P/chore/add-yarn-support
Add yarn lock files
2019-04-15 15:54:38 +00:00
bumi b13bf6e8b0 Readme: add note about locally running out of funds 2019-04-15 15:59:54 +02:00
bumiandGitHub 8dcad88372 Merge pull request #99 from 67P/update-seeds
Update seeds
2019-04-15 10:39:10 +00:00
bumiandGitHub b6c06c289c Merge pull request #95 from 67P/cosmetics
Cosmetic cleanups
2019-04-12 18:55:59 +00:00
bumiandGitHub f405e39c04 Merge pull request #94 from 67P/bugfix/schema_changes
Refactor contribution serializer and validation
2019-04-12 18:54:56 +00:00
bumi 27e5190e29 Production release to rinkeby
Deployed all apps and created a new Kredits DAO
2019-04-10 18:28:24 +02:00
bumi 4d2e0ea84b Update Token symbol 2019-04-10 15:50:33 +02:00
bumi 26d12ba239 Store kredits tokens as wei with 18 decimals
This stores the tokens with 18 decimals as most other tokens and as
assumed by a potential future token standard EIP 777.
2019-04-10 13:59:00 +02:00
bumi f21c4cf9de Fix confirmed contribution check
If the blocknumber is higher or equal the contribution.confirmedAt block
number then the contribution is confirmed and can be claimed.
2019-04-09 22:30:17 +02:00
bumiandGitHub 9ca0580db6 Merge pull request #85 from 67P/dev/fix_seeds
Fix contributor ID in seeds
2019-04-09 07:33:42 +00:00
bumi 65d9cf2a06 Fix bootstrap
This runs npm install for every app through a postinstall hook.
2019-04-08 18:10:13 +02:00
bumiandGitHub b35dc2049b Merge pull request #82 from 67P/dev/list_contributions
Improve list-contributions script
2019-04-06 19:40:24 +00:00
bumiandGitHub cc24c27444 Merge pull request #80 from 67P/chore/rename-ipfshash-1
Rename ipfsHash to hashDigest in Contributor
2019-04-06 13:55:19 +00:00
bumi f717968402 Better function naming to update contributor profiles 2019-04-06 15:42:16 +02:00
bumi 14d7fbd75e Rename ipfsHash to hashDigest in Contributor
naming should be consistent with the other contracts and digest is more
correct.
2019-04-06 15:24:44 +02:00
bumi a0e4f5410d Set veto period to 1 week
This makes a contribution claimable after roughly 7 days
2019-04-05 20:30:02 +02:00
bumi 766463b57b Dynamic function to test for core contributor flag
This removes the isCore flag and allows us to dynamically calculate the
core flag for contributors.

For now this is just us (the first 6 contirbutors)

Also we do not need the default contributor anymore because the deploy
user has the role to manage contributors and can create the first real
contributors.
2019-04-05 18:55:21 +02:00
bumi 6510dca4b1 Fix provider fallbacks for non dev networks
This now checks if frame or a local node is running and else uses infura
to connect to the ethereum network.
Now you can use all the helpers for the testnets/mainnet without running
anything (in readonly mode)
2019-04-05 13:51:23 +02:00
bumi 551edcfa72 Fix init kredits for readonly providers
The apm option was not passed on to kredits
2019-04-05 01:05:16 +02:00
bumi d58e2d560a deploy to rinkeby 2019-04-05 00:38:51 +02:00
bumiandGitHub 99394e7f14 Merge pull request #73 from 67P/feature/contribution_owner
Convert contribution owner to ID, use smaller number formats
2019-04-04 21:40:16 +00:00
bumi 8ceab08bfc ups 2019-04-04 23:23:02 +02:00
bumi afbd114a36 Add app upgrade helper script
This script deploys a new app version, upgrades the given DAO to the
latest version of that app and builds the ABI files for the wrapper.

usage:

    scripts/upgrade.sh <app name> <dao address>

e.g.

    scripts/upgrade.sh token 0xfoobar

The DAO address can also be set as environment variable
$KREDITS_DAO_ADDRESS
2019-04-04 19:51:38 +02:00
bumi db312dafbf Add some helpers to reset a fresh DAO 2019-04-04 19:27:57 +02:00
bumiandGitHub 732dfe7b29 Merge pull request #71 from 67P/chore/update_seeds
Update seeds
2019-04-04 11:32:58 +00:00
bumiandGitHub 3ce8f41d32 Merge pull request #72 from 67P/chore/whitespace
Remove unnecessary space chars
2019-04-04 11:17:35 +00:00
bumi 6b9466c348 Update seeds
Claim contribution which issues Kredits to the contributor
2019-04-03 21:40:37 +02:00
bumi 9fffdbfb58 Fix permissions to manage contributors
Uses the contributor oracle to decide if somebody has the
MANAGE_CONTRIBUTOR_ROLE
2019-04-03 21:22:53 +02:00
bumi 70b9edbcac Update ipfs package 2019-04-03 21:01:51 +02:00
bumiandGitHub 6fed81c0ed Merge pull request #66 from 67P/chore/seeds
Allow seed tx to fail
2019-04-03 17:03:22 +00:00
bumi 74e61e1393 Show balance in list-contributors helper script 2019-04-03 14:05:16 +02:00
bumi 6351db3057 Add balance when loading contributor
This is a regression introduced by the latest contract updates.
Now we return the balance again when loading contributor data.
2019-04-03 13:56:52 +02:00
bumi 9984ca66ba Use namehash from ethers.utils
no need for the additional dependency
2019-04-03 10:24:11 +02:00
bumi 1b09a30646 Fix contributor oracle permission auth
It seems that the entity is either defined by the permission or if we
want to use the oracle the permission must be defined for any_entity.
In that case the oracle does not get the msg.sender as who/entity thus
we will use tx.origin in that case.
2019-04-03 10:06:00 +02:00
bumi 91135dbc82 Fix deploy-kit helper script
We no longer need the app ids as json. Those are dynamically calculated
now
2019-04-02 18:06:33 +02:00
bumi ce446e530d Set Kreits apm from arapp.json file in helper scripts
different networks might require different apm domains. We set those in
the arapp.json file which we can reuise to init the kredits instance in
the helper scripts.
2019-04-02 09:58:44 +02:00
bumi fedb10c5da Dynamically get app ids from the namehash
This dynamically hashes the app id which makes it easier to manually set
contract addresses. This is useful in development environments with no
default network ids.
The used apm (which is part of the app id hash) is configurable.

usage:

new Kredits(provider, signer, { addresses: { Kernel: '0x...' }, apm: 'aragonpm.eth' })
2019-04-01 22:41:00 +02:00
bumi 61fa26da7a Add more information output to the send funds helper 2019-04-01 11:53:50 +02:00
bumi 51e5da414f Update ethers.js to latest version v4
The main change is how ethers loads the networkId which is now async.
Thus the init process had to change a bit
2019-03-29 18:13:51 +01:00
bumi 3662f1ae24 Add Operator getter for backwards compatibility 2019-03-29 15:03:37 +01:00
bumi c568263fea update eth-provider to support different providers
Ideally eth-provider checks which connection is available and uses the
available one.
frame => local node => infura

But it seems there is still a bug and it raises an error if frame is not
available.
But at least we can use frame now for testnet/mainnet deployments
2019-03-29 12:08:07 +01:00
bumi 38079d07db remove debug console 2019-03-29 12:07:52 +01:00
bumi 0cc67c2fad Support getting the network version from different web3
version/providers
2019-03-29 12:07:09 +01:00
bumi a45be0021e Fix old registry reference 2019-03-29 12:06:43 +01:00
bumi 4bd1aed197 Refactor kredits init in helper scripts
This now also supports readonly providers like infura
2019-03-29 12:05:51 +01:00
bumi 94832d4d07 Add ACL contract wrapper
this mainly allows us to check if an account has a certain role and thus
if the account can call specific contract functions.

At some point we might want to extend that to support the check if an
account can call the function. For that we would need to have a mapping
between function names and roles, which we have not right now.
2019-03-28 12:39:04 +01:00
bumi 4f5ae01c5a Add helper funtion to list contract entries 2019-03-28 11:16:20 +01:00
bumi d6f99f57b7 Auto resolve promises in repl 2019-03-28 11:12:32 +01:00
bumi 901566d1ff Update network specific addresses and app ids 2019-03-28 11:11:49 +01:00
bumi 5d4be8f176 Update ABIs used by wrapper 2019-03-28 11:09:49 +01:00
bumi f9ab8b225a Fix proposal wrapper to support the latest contracts 2019-03-28 11:08:34 +01:00
bumi dfa55516ec Add contribution veto function
Allows anybody with the VETO_CONTRIBUTION_ROLE to veto a contribution
and thus prevent that the contribution can be claimed.
So far like the ADD_CONTRIBUTION_ROLE any contributor is allowed to
veto.
2019-03-28 11:06:19 +01:00
bumi b6f34ac9a5 Pretty print JSON for contract addresses
This makes it easier to read the file and a git diff is more useful
2019-03-27 21:58:19 +01:00
bumi 258c6729b6 Cleanup scripts and use helper to get the networkid 2019-03-27 17:06:52 +01:00
bumi b201642485 remove obsolete comment 2019-03-27 16:56:52 +01:00
bumi 0686c79998 Print dao address and kreditskit address 2019-03-27 16:56:24 +01:00
bumi 7e68dbf8c2 rinkeby deployment 2019-03-27 00:39:00 +01:00
bumi f5973756c8 Dynamically set AppIds
AppIds are used to lookup the actual contract addresses of each app.
Because of different registry names (open.aragonpm.eth vs. aragonpm.eth)
we have to use different ids in the local dev chain and in the
testnet/mainnet. To allow this we need to set the appids dynamically.

There is an open aragon issue to solve this and also allow to use
open.aragonpm.eth in the devchain by default.
https://github.com/aragon/aragen/issues/10
2019-03-27 00:21:06 +01:00
bumi 9cc237fbf4 Support web3 providers that do not support sync calls
This is currently the non default web3 provider used for rinkeby etc.
2019-03-26 00:35:22 +01:00
bumi 3584a73c08 Set kredits-<name>.open.aragonpm.eth as appid hashes 2019-03-26 00:34:46 +01:00
bumi 3c2cdf4376 Deployment hacking while trying to deploy on rinkeby
This currently breaks the local usage because of the different appIds:
<name>.open.aragonpm.eth vs. <name>.aragonpm.eth (local)
2019-03-26 00:18:59 +01:00
bumi fbda45376e cleanup contract debugging and make sure contributions are only once claimable 2019-03-24 22:33:16 +01:00
bumi cd7df3893e readme 2019-03-24 22:18:19 +01:00
bumi e1fea4ed97 refactor DAO deployment 2019-03-24 22:11:24 +01:00
bumi 12341d1526 Add script to print current DAO address 2019-03-24 16:09:00 +01:00
bumi 14b23ecdf1 move app bootstrap script to scripts 2019-03-24 15:45:48 +01:00
bumiandGitHub 1679afb9b4 formatting 2019-03-24 14:43:43 +00:00
bumi b03095e149 Cleanup and readme
simplify bootstrap
2019-03-24 15:40:46 +01:00
bumi 0d9b2d7d58 readme 2019-03-24 11:01:59 +01:00
bumi e7affdb531 updated npm scripts 2019-03-24 00:58:56 +01:00
bumi 1594bf0e17 update seeds 2019-03-24 00:39:46 +01:00
bumi 203199c268 cleanup 2019-03-24 00:21:36 +01:00
bumi 116f69cb12 cleanup 2019-03-24 00:20:48 +01:00
bumi 6c569239de refactor contrats with aragonos 2019-03-23 19:15:23 +01:00
bumi d687ff604e Merge branch 'master' into contribution-contract
* master:
  Update truffle and ganache-cli
2018-09-29 19:54:28 +02:00
bumi c9a4b1decc Update truffle and ganache-cli 2018-09-29 19:52:14 +02:00
bumi dae44cac70 Continue Contribution contract and JS wrapper 2018-09-29 19:46:37 +02:00
bumi 6b8f718051 Create contribution when proposal gets executed 2018-06-18 18:43:35 +02:00
bumi 75d426f0cc Add Contribution contract
The contribution contract implements an ERC721 interface which
represents any contribution.
The contributions are non-fungible (as opposed to the Kredits tokens)
and can be not be transferred. The contract stores the history of any
contribution.
Contributions can be claimed which will issue the Kredits tokens to the
contributor.

This is an early implementation and misses some access control and
probably more things.
2018-06-18 15:28:50 +02:00
bumi 7ce100e819 3.0.2 2018-06-15 09:44:11 +02:00
bumi 7216522d83 Update Operator ABI 2018-06-15 09:42:29 +02:00
bumiandbasti 956f858620 Rename healthcheck to preflight 2018-06-07 16:39:07 +02:00
bumi 017073018f Use more readable Array.every method instead of reduce 2018-04-26 15:35:32 +02:00
bumi fe1fa2e881 Allow filter and find for contributors by account data 2018-04-26 14:51:18 +02:00
bumiandGitHub c367c9cf6b Merge pull request #44 from 67P/add-contributors-alias
Add Contributors alias for Contributor
2018-04-26 11:52:23 +00:00
bumi 52643da096 typo 2018-04-26 13:52:09 +02:00
bumi 3895553e88 Use destructuring for options
This makes it more readable what options are used
2018-04-26 10:23:27 +02:00
bumi 89261d039a Fix contributor id lookup for proposal creation script 2018-04-26 02:42:31 +02:00
bumiandGitHub ce5f5fb8d2 Merge branch 'master' into features/batch-voting 2018-04-24 12:39:16 +00:00
bumi 2e8d00bc2c Add a filter by account function to contributors
This allows to filter contributors by the account entries.
For example:

```js

Contributor.filterByAccount({site: 'github.com'}); // returns all
contributors with github account
Contributor.filterByAccount({site: 'github.com', username: 'bumi'});
// returns bumi

```
2018-04-23 16:29:44 +02:00
bumi b1345b53f3 Add repl.js helper script
This is similar to the cli.js helper but only provides an initialized
`kredits` instance.
The cli.js is for executing contract functions
2018-04-23 16:24:40 +02:00
bumi 847f5a251c Allow funding accounts with the seeds script 2018-04-23 13:43:35 +02:00
bumi 62a5cefd1a Update readme to reflect helper script changes 2018-04-23 13:20:57 +02:00
bumi 6378df7075 cleanup 2018-04-23 12:11:26 +02:00
bumi bd2af6ed72 Smarter cli script
It now allows you to list available functions and allows to call
functions on the wrapper or on the contract directly.
2018-04-23 12:10:20 +02:00