open-bounty
open-bounty copied to clipboard
Documentation to be able to collaborate
Type: Meta (not a feature nor a bug)
User Story
As a developer, I want to read and overview of the project and its status to know how it works by and large so that I know better how it works and decide to play with it and collaborate.
As a developer, I want detailed instructions about how to make the project run in local so that I can start playing with it and collaborating.
As a developer, I want to know what technology I need to know and some good resources to learn them to play/collaborate with the project, so that I am able to collaborate.
Expected behaviour
See all that info in the very same repository, so that it can be maintained with repo powers (versioning, pull requests, bounties).
Actual behaviour
Little information, and not complete (I just tried to install the project locally and couldn't get it yet because of some errors about tokens in web3j contracts).
I'm going to leave here the errors I'm getting so that they serve as things to solve in the documentation.
Right now when I try to start mount, I'm getting this:
#error {
:cause nil
:via
[{:type java.lang.RuntimeException
:message "could not start [#'commiteth.eth.token-data/token-data] due to"
:at [mount.core$up$fn__100 invoke "core.cljc" 92]}
{:type java.lang.NullPointerException
:message nil
:at [clojure.lang.Reflector invokeNoArgInstanceMember "Reflector.java" 301]}]
:trace
[[clojure.lang.Reflector invokeNoArgInstanceMember "Reflector.java" 301]
[commiteth.eth.token_registry$load_parity_tokenreg_data invokeStatic "token_registry.clj" 42]
[commiteth.eth.token_registry$load_parity_tokenreg_data invoke "token_registry.clj" 33]
[commiteth.eth.token_registry$load_parity_tokenreg_data invokeStatic "token_registry.clj" 37]
[commiteth.eth.token_registry$load_parity_tokenreg_data invoke "token_registry.clj" 33]
[commiteth.eth.token_data$update_data invokeStatic "token_data.clj" 23]
[commiteth.eth.token_data$update_data invoke "token_data.clj" 15]
[commiteth.eth.token_data$eval55003$fn__55004 invoke "token_data.clj" 30]
[mount.core$record_BANG_ invokeStatic "core.cljc" 86]
[mount.core$record_BANG_ invoke "core.cljc" 85]
[mount.core$up$fn__100 invoke "core.cljc" 93]
[mount.core$up invokeStatic "core.cljc" 92]
[mount.core$up invoke "core.cljc" 90]
[mount.core$bring invokeStatic "core.cljc" 210]
[mount.core$bring invoke "core.cljc" 202]
[mount.core$start invokeStatic "core.cljc" 252]
[mount.core$start doInvoke "core.cljc" 244]
[clojure.lang.RestFn applyTo "RestFn.java" 137]
[clojure.core$apply invokeStatic "core.clj" 646]
[clojure.core$apply invoke "core.clj" 641]
[mount.core$start_without invokeStatic "core.cljc" 369]
[mount.core$start_without doInvoke "core.cljc" 364]
[clojure.lang.RestFn invoke "RestFn.java" 408]
[user$start invokeStatic "user.clj" 7]
[user$start invoke "user.clj" 6]
[user$eval66758 invokeStatic "form-init3216533915028760681.clj" 1]
[user$eval66758 invoke "form-init3216533915028760681.clj" 1]
[clojure.lang.Compiler eval "Compiler.java" 6927]
[clojure.lang.Compiler eval "Compiler.java" 6890]
[clojure.core$eval invokeStatic "core.clj" 3105]
[clojure.core$eval invoke "core.clj" 3101]
[clojure.main$repl$read_eval_print__7408$fn__7411 invoke "main.clj" 240]
[clojure.main$repl$read_eval_print__7408 invoke "main.clj" 240]
[clojure.main$repl$fn__7417 invoke "main.clj" 258]
[clojure.main$repl invokeStatic "main.clj" 258]
[clojure.main$repl doInvoke "main.clj" 174]
[clojure.lang.RestFn invoke "RestFn.java" 1523]
[clojure.tools.nrepl.middleware.interruptible_eval$evaluate$fn__25412 invoke "interruptible_eval.clj" 87]
[clojure.lang.AFn applyToHelper "AFn.java" 152]
[clojure.lang.AFn applyTo "AFn.java" 144]
[clojure.core$apply invokeStatic "core.clj" 646]
[clojure.core$with_bindings_STAR_ invokeStatic "core.clj" 1881]
[clojure.core$with_bindings_STAR_ doInvoke "core.clj" 1881]
[clojure.lang.RestFn invoke "RestFn.java" 425]
[clojure.tools.nrepl.middleware.interruptible_eval$evaluate invokeStatic "interruptible_eval.clj" 85]
[clojure.tools.nrepl.middleware.interruptible_eval$evaluate invoke "interruptible_eval.clj" 55]
[clojure.tools.nrepl.middleware.interruptible_eval$interruptible_eval$fn__25457$fn__25460 invoke "interruptible_eval.clj" 222]
[clojure.tools.nrepl.middleware.interruptible_eval$run_next$fn__25452 invoke "interruptible_eval.clj" 190]
[clojure.lang.AFn run "AFn.java" 22]
[java.util.concurrent.ThreadPoolExecutor runWorker "ThreadPoolExecutor.java" 1142]
[java.util.concurrent.ThreadPoolExecutor$Worker run "ThreadPoolExecutor.java" 617]
[java.lang.Thread run "Thread.java" 745]]}
I don't know if I am using a wrong address somewhere.
In :eth-account I have one that I created myself.
In :tokenreg-addr I have 0x7d127a3e3b5e72cd8f15e7dee650abe4fcced2b9, which I copied from commiteth.eth.token-registry
In :contract-factory-addr I have 0x47F56FD26EEeCda4FdF5DB5843De1fe75D2A64A6, which I copied from commiteth.eth.multisig-wallet.
@tpatja What do you think?
This error happens because token registry data cannot be found on the chain at address 0x7d127a3e3b5e72cd8f15e7dee650abe4fcced2b9 . Make sure your geth is synced and connected to a chain that actually has the data at that address.
For a dev env setup that uses Ropsten testnet you should have at least these:
:on-testnet true
:tokenreg-base-format :status
:tokenreg-addr 0x7d127a3e3b5e72cd8f15e7dee650abe4fcced2b9
@tpatja Thanks! :)
Yes, I have geth working as it is described in the readme. Just changed the option :tokenreg-base-format to :status (I had it in the default :parity, and the other two I had them like you just described) but it keeps failing.
Any other idea? :S
Please connect to your ropsten geth instance from the command line with geth like this and paste the output:
$ geth attach ~/.ropsten/geth.ipc
@tpatja Here you go:
Welcome to the Geth JavaScript console!
instance: Geth/v1.7.3-stable/darwin-amd64/go1.9.2
coinbase: 0x84c21d54e34da7100bb21bc696e13542bef71d87
at block: 0 (Thu, 01 Jan 1970 07:00:00 ICT)
datadir: /Users/pablodip/.ropsten
modules: admin:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 rpc:1.0 txpool:1.0 web3:1.0
at block: 0
It's not synced. Current block should be more than ~2340238.
@tpatja Indeed, it wasn't fully synced. :S It is working now. Thank you! :)
It finally works for me. Things that were different from README guide:
- I'm using
lein with-profile +precomp replinstead oflein repl. Otherwise, i getCaused by: java.lang.ClassNotFoundException: commiteth.eth.contracts.TokenReg, compiling:(commiteth/eth/token_registry.clj:1:1)(it's documented insideproject.cljbut that's not noticable at first glance) - Had to comment out
:contract-factory-addrand:tokenreg-addrto letenvuse default values instead. You discussed that already above. - Use
parityinstead ofgeth(becausegethfor some reason stuck at block593687and doesn't sync further. Syncing from scratch afterremovedbdidn't also work out for me). - I did
cp -r static_langing_page/fonts resources/public/fontsto copy missing fonts
What doesn't work in my current setup:
- ~~figwheel doesn't reload the code (figwheel_server.log shows that browser has been notified though). This might be related to the fact that i'm also running figwheel for status-react project (port is different though).~~ Was related to wrong figwheel port, works now.
- ~~CSS files doesn't get updated (while
lein with-profile +precomp less autois running and listening for changes)~~ same as above
@dmitryn Does it work for you to create a bounty in an issue? To me it keeps telling pending deployment. It does send a transaction though: https://ropsten.etherscan.io/tx/0xf51e1093da3cb2f9f74bf07c6f9c3aee3818c2e77279e032a9dfede7df58eec8
@pablodip not sure. I'm doing everything locally and now sitting at https://github.com/status-im/open-bounty/blob/develop/doc/testing.md#creating-bounty-issues "bounty" label didn't appear on my test repo that i added to SOB
@dmitryn What do you mean with "everything locally"? Are you using a private local ethereum network? Regarding the label, you can create labels freely on Github repos.
@pablodip i mean i'm using local app (not staging https://openbounty.status.im:444/) with ropsten network. The issue is that local app cannot see any of my GH repos (i'm getting 404 on 'user/repos` request). Something is wrong with GH authorization on my end i guess.
@pablodip
Does it work for you to create a bounty in an issue?
For me it's failing on contract deploying:
2018-01-03 20:47:36,189 [nREPL-worker-35] DEBUG commiteth.bounties - Adding bounty for issue cljs-expo-demo-project 1 owner address: 0x003BB511405D7a61216c11D1860EeB74aD722F2E
2018-01-03 20:47:36,189 [nREPL-worker-35] DEBUG commiteth.bounties - deploying contract to 0x003BB511405D7a61216c11D1860EeB74aD722F2E
2018-01-03 20:47:36,204 [nREPL-worker-35] DEBUG commiteth.eth.core - args: {:data 0xf8f7380800000000000000000000000000000000000000000000000000000000000000400000000000000000000000
0000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002000000000000000000000000007d24f26E10DBbA4DCbF0DE68aFd63AFa5d204e00000000
0000000000000000003BB511405D7a61216c11D1860EeB74aD722F2E, :gas 0xd32e8, :from 0x007d24f26E10DBbA4DCbF0DE68aFd63AFa5d204e, :value 0x0, :gasPrice 0x4a817c800}
2018-01-03 20:47:36,213 [nREPL-worker-35] DEBUG commiteth.eth.core - {"jsonrpc":"2.0","method":"personal_sendTransaction","params":[{"data":"0xf8f73808000000000000000000000000000
0000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000020000000000000
00000000000007d24f26E10DBbA4DCbF0DE68aFd63AFa5d204e000000000000000000000000003BB511405D7a61216c11D1860EeB74aD722F2E","gas":"0xd32e8","from":"0x007d24f26E10DBbA4DCbF0DE68aFd63AFa5
d204e","value":"0x0","gasPrice":"0x4a817c800","to":"0x47F56FD26EEeCda4FdF5DB5843De1fe75D2A64A6"},"XXXXXXXX"],"id":2643}
{:jsonrpc 2.0, :error {:code -32601, :message Method not found}, :id 2643}
2018-01-03 20:47:36,214 [nREPL-worker-35] ERROR commiteth.bounties - Failed to deploy contract to 0x003BB511405D7a61216c11D1860EeB74aD722F2E
UPD: Got rid of that error.
Started parity with proper flags parity --rpcapi 'eth,net,web3,personal'.
@dmitryn Nice! :) Does it get stuck to you when checking the deployment with "pending deployment" or does it complete the process?
@pablodip yes, it's still pending, despite transaction got through. Will take a look at it closer when i'll have time.
@tpatja Any idea why it keeps telling pending deployment to us when creating a bounty? :S
Hi guys,
I'm having a couple of issues getting this up and running. Very newbie ones. Will appreciate any help!
- What fields should be populated in
env/dev/resources/config.edn? - Also, what password should go under --password option to geth command? I've created an account on Ropsten through MetaMask, but not sure what should be placed there.
- https://openbounty.status.im:444: been following through testing.md. Logged in using my GitHub account and allowed access. However, in recent commits Repositories tab has been disabled, so how do I authorize open-bounty on specific repos?
- After running
(user/start)i get an error complaining that the location for:eth-wallet-filehas not been found. Naturally because I haven't provided anything different from default/some/location. What should I put there?
@siphiuel
Regarding 2 & 4 , you could use geth to create account and set password. Also, it will provide you with json file (:eth-wallet-file) containing private key https://github.com/ethereum/go-ethereum/wiki/Managing-your-accounts
@dmitryn Thanks, this worked beautifully! Got the account/password and wallet file now. In geth log I see that account was unlocked.
Now in the REPL after running (user/start) it complains that ConnectException Connection refused (Connection refused) java.net.PlainSocketImpl.socketConnect (PlainSocketImpl.java:-2). I'm checking what more is missing in config.edn.
@siphiuel Regarding the connection refused, make sure you set the same rpc port in geth and in the config.edn, since by default the readme says 8545 for geth and the config.edn says 8547 (:eth-rpc-url key).
@pablodip thank you! Made the change, it fixed the ConnectException.
Now there is a NullPointerException, I've added a try-catch block and it originates in commiteth.eth.token-data/update-data: :testnet-token-data env variable is not found, and it attempts to fetch parity tokenreg data. Which should not be right. Why does it attempt to read :testnet-token-data when it's nowhere to be found?
Also, I've checked output of geth attach ~/.ropsten/geth.ipc, and it says that block is 0. How to force it to sync?
Sorry for so many questions.
@siphiuel NPE means you have not synced geth so it cannot find token registry deployed.
Block 0 info confirms that. I also had that issue with geth and switched to parity to overcome syncing issue.
@siphiuel the NullPointerException because token registry data cannot be found from the configured :tokenreg-addr on the current chain. Also your ethereum client is not synced, since it's at block 0.
If on testnet (for development you should use Ropsten), you should set these:
:tokenreg-base-format :status
:tokenreg-addr 0x7d127a3e3b5e72cd8f15e7dee650abe4fcced2b9
Added devops to user story: As a devops I want documentation about how to run and maintain the project so that I know how to make it work and maintain it.
I am reopening this issue, since there are still some user stories here to tackle.