[BOUNTY] Crowdfunding DAPP

mids106mids106 ✭✭✭Member Posts: 188 ✭✭✭
edited February 2015 in Smart Contracts and Dapps
Vitalik has previously created a crowdfunding contract, https://github.com/ethereum/serpent/blob/develop/examples/crowdfund.se and even created a user interface for it: https://github.com/ethereum/dapp-bin/tree/master/crowdfund

However this work isn't currently maintained, and Serpent won’t be officially supported in V1. Your goal is to make this contract and its user interface usable on Ethereum POC-8 and ready for Genesis Day.

All core features should be exposed through the UI and access the companion contract:
- Link to a campaign via the URL
- Create a campaign
- Contribute to a campaign
- If sufficient funding received, payout to campaign recipient
- If expired, refund to contributors
- Display progress report of a campaign

Rules & Criteria:
1) Contract should be implemented using Solidity. (you could use the Solidity port of Vitalik’s contract as starting point https://github.com/chriseth/cpp-ethereum/wiki/Crowdfunding-example-contract-in-Solidity )
2) Frontend to use the ethereum.js API
3) Use a JavaScript framework such as Angular, Backbone, Meteor, React, etc.
4) Hosting of frontend assets (HTML + JS) on static server (ie GitHub pages)
5) No backend required (besides local Ethereum node and static www server)
6) Deployed on POC-8 (or later) testnet
7) UI fully works from within AlethZero, Mist and external browser using Ethereum's JSONRPC API (HttpSyncProvider).
8) All components open source & published on GitHub
9) DEV employees & contractors are excluded
10) Bounty donations are non-refundable

Bounty Award:
0.5 BTC (as of 2015-02-03)
https://blockchain.info/address/1BHBJkboatpGaZykmQqwHHEshm4iuAkRg

Claim the bounty:
- Post your submission (including GitHub URL and Bitcoin address) as comment in this thread
- The ruling for this bounty will be by this post’s author

Comments

  • fractastical2.0fractastical2.0 Member Posts: 1
    edited February 2015
    I'll add 1.5 BTC to this bounty if it is good and we can use it as a sample in VAPOR.
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    I'll see what I can do.
  • mids106mids106 ✭✭✭ Member Posts: 188 ✭✭✭
    Let me address two questions that I received privately:

    1. Do you want a fully functional crowd funding platform for multiple users/campaigns or just one user and their campaigns?

    A: The DApp should support multiple users/campaigns, just like Vitalik's contract does. There is already enough risk in a crowdfunding campaign itself, I wouldn't want having to review the platform for each individual campaign on top of it. So by having a shared (and open source) platform, it can remain objective and well peer reviewed.

    2. What about content, such as details about the campaign, do you want those left out?

    A: Storing text, such as a campaign description, links to youtube videos, comments, status updates, etc in the contract storage would most likely be too extensive. In the future we might be able to use Swarm for this; but that is out of the scope of this bounty. To specify an authoritative source for content & updates, storing a single URL might be good enough for now. Suggestions are welcome how to make something operable while keeping the cost down.
  • mids106mids106 ✭✭✭ Member Posts: 188 ✭✭✭
    Some hints / suggestions for those working on the crowdfunding bounty:

    1) There is a design flaw in the Solidity contract; when you 'start' a new bounty it is supposed to return the campaign id. However when sending a transaction to an ethereum contract, you won't get any results back (since the outcome depends on the miner that will eventually mine the block). Using 'call' you can get a result back, but this won't have any side effects / your campaign won't be created.
    Vitalik has solved this in his contract by letting the creator specify the campaign id upfront. Another (recent) solution to this would be to use the 'LOG' operator (Event in Solidity) and in the frontend watch for the result of this.

    2) It is a requirement to be able to link to a specific campaign directly (by its id). This would allow campaign creator to refer to it on their website, blog, forum post, etc. For bonus browny points you could create a widget that can be embedded on any site showing the campaign progress.
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    edited February 2015
    My go at it (presently un-deployed on POC8 testnet) tested locally on Mist/AlethZero .

    Hosted front-end (for display purposes): http://crowdfundrr.github.io/
    Git: https://github.com/CrowdFundrr/CrowdFundrr
  • mids106mids106 ✭✭✭ Member Posts: 188 ✭✭✭
    @SilentCicero thanks for your submission! I'll evaluate it and let you know my findings
  • mids106mids106 ✭✭✭ Member Posts: 188 ✭✭✭
    @SilentCicero I have reviewed your submission and written an extensive report: https://gist.github.com/jorisbontje/709bf86f56ed5ffc54ab

    Summary:
    Nice first impression, good presentation & companion website.
    Solidity contract compiles, but has a few bugs; I wasn't able to deploy & test it; the contract in easydeploy.html doesn't get mined. No testnet deployment to try; unable to verify that the provided functionality actually works.
    Javascript is unstructured 'oldskool' jquery, mixing UI and logic. Not using a web application framework.
    Very promising progress, but needs a little work to make this demonstrable!
    Also please provide your bitcoin address for future bounty payout ;)
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    edited February 2015
    Hmm, that's strange, the contract deploys fine on my Aleth and Go Ethereum CLI from easydeploy. What bugs specifically? I'll test the deployment again. As for the framework, I'll move it into angular, with bower components. Apologies for the js, I really did scratch it up pretty quick, your right it is pretty old-school jquery at best. I'll toss it into Angular today, and do bower for bootstrap, ethereum.js, jquery etc. I've been meaning to do this for a while now. Cheers @mids106, thanks for the review!
  • kobigurkkobigurk Member Posts: 4
    I tried using it as well after mids pointed out it was available, the problems I had:
    1. the contract was not deployed in the testnet, so the address specified in the code was not relevant.
    2. even after changing the contract address, the transactions would not cause the contract storage to change.
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    edited February 2015
    @kobigurk yeah, I didn't deploy it on testnet yet. I obviously need to do some reworking, right now I'd consider this still in alpha. I'm rebuilding this and testing for the new go and aleth clients, I'm also going to use Angular (much more reliable) and just clean up a few things in general. Perhaps some of the newer editions of Go and Aleth are causing issues. I'll admit I've been testing on some older versions (like a 5 days old, but still). I'll post updates in this thread to keep people posted.
  • kobigurkkobigurk Member Posts: 4
    @SilentCicero , totally get that it's an alpha! can't wait to play with it.
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    The Angular build is going well, I moduled the font-end and am just working on services. It's like a three-way high working between Ethereum Go, Angular and bootstrap. Web3 (if I may call it that) has so far been amazing. Worlds are colliding.
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    Angular build is up with new solidity contracts. Not deployed on POC 8 (will be doing that shortly). https://github.com/CrowdFundrr/CrowdFundrr
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    I'm proud to announce CrowdFundrr has officially changed its name to WeiFund.

    The new Github is: http://github.com/weifund/weifund

    And our brand new site is: http://weifund.io

    Cheers, SC
  • mids106mids106 ✭✭✭ Member Posts: 188 ✭✭✭
    After reviewing the `meteor` branch of WeiFund, I conclude that @SilentCicero has passed all criteria for this bounty!

    The development of WeiFund is still in progress, do check it out and lend your hands to this great effort.

    Also keep an eye on SC's other work:
    * https://github.com/SilentCicero/meteor-dapp-pricefeed
    * https://github.com/SilentCicero/meteor-dapp-boilerplate

  • StephanTualStephanTual mod London, EnglandMember, Moderator Posts: 1,282 mod
    Congrats @SilentCicero - well deserved!
  • terzimterzim LondonMember Posts: 41
    @SilentCicero starting from the Crowdfunding contract, it should be then easy to implement a "Loan Agreement Dapp", whereas the funds which are raised are then returned to the funders after a given grace_period, within a given tenor, and paying interest at a given interest_rate.

    Any thoughts on implementation?

    Thanks - Massi
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    Yes, my new update will cover contract config integration for WeiFund. If a config contract address is set for your crowdfunding campaign, it will send your contract, specific contributor data when a contributor donates (i.e. campaign id, contributor address and contribution amount). You can design your Loan Agreement contract around that incoming data from WeiFund (I will be providing examples soon). Alternatively, you can setup a middle man contract to interpret the said data and send it to your Loan Agreement Contract. Fundamentally, you can do what ever you want with that data (i.e. setup any contract(s) you like to intemperate or use the contribution data securely). All of this will be included with WeiFund's next commit (along with some other goodies and redesigns).

    You will have to work out the ramifications of your contract design, but know that WeiFund can securely send your contract in real time the pertinent contributor data when someone contributes to your campaign.

    Cheers, hope this helps! SC
  • terzimterzim LondonMember Posts: 41
    Amazing @SilentCicero .

    I will see where I can get to using your code as a base and the explanation above. I will share output on GitHub once I am there. Looking forward to your WeiFund extensions too.

    Have a good start of the week. Massi
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    Just built in Youtube/Vimeo support for WeiFund w/ config address capability. So @terzim you can now connect any contract to your campaigns, e.g. token system, middle ware, or whatever (so long as it follows the WeiFundConfig). Let me know how it goes, just know that this commit was more about video than config extension.
  • terzimterzim LondonMember Posts: 41
    @SilentCicero what's the best way to contact you in private? :) message on forum / skype / email / carrier pigeon?
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
  • Ether-LordEther-Lord Member Posts: 7
    edited May 2015

    Congrats @SilentCicero - well deserved!

    Yes, @SilentCiceo congratulations! This idea is brilliant. I will be following the development of WeiFund closely. Is there an ETA (even quarterly) on when you guys hope to launch?
  • SilentCiceroSilentCicero ✭✭✭ Toronto, CAMember Posts: 159 ✭✭✭
    @Ether-Lord thank you, WeiFund should have a complete implementation working beta for Frontier (as right now only the working alpha is available on our Github). A formal press package will be deployed when we have a build we feel comfortable releasing. No hard release dates have been set just yet.
Sign In or Register to comment.