Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code Faucet Page #184

Closed
owocki opened this issue Dec 28, 2017 · 30 comments
Closed

Code Faucet Page #184

owocki opened this issue Dec 28, 2017 · 30 comments

Comments

@owocki
Copy link
Contributor

owocki commented Dec 28, 2017

Spec

Very often, I get people who want to claim an issue on Gitcoin but can't because they don't have ETH. Either there are no exchanges in their area, or they dont have the mone yto spend on gas.

Pursuant to making ethereum and Gitcoin accessible to everyone as broadly as possible, I would like to design a page entitled 'faucet' in which a user can go to the page and submit an application to receive a small amount of ETH.

Functional spec:

  • Design ( Design: Faucet page #173 (comment) ) will be responsive
  • All inputs are required.
  • Form input Email address should be validated to be an email
  • Form input ETH address should be prefilled with the users' metamask web3.eth.coinbase address, and should be validated as an ethereum address.
  • The form should not allow users to submit more than once per github account.
  • when the form is submitted a new row will be stored in FaucetApplication ( a new model)
  • when the form is submitted, an email will be sent to settings.SERVER_EMAIL notifying the admin of the faucet application.
  • the above email should have a link to a page in the admin which will allow the 'faucet' to be fulfilled
  • the page in the admin should show all fields from the form and have a 'fulfill' button which will trigger a 0.003 ETH payment to the ETH address, and then, upon success, mark the faucet object as fulfilled and send an email notifying the recipient that their faucet request has been funded.

New database model proposal

FaucetApplication
-pk

  • created_on
  • modified_on
  • fuilfilled (bool)
  • Github profile
  • ETH address
  • email address
  • comments
  • Github metadata

References

#173 (comment)
frontend design for this page: #184

Bounty

Please only claim this bounty if you can turn it around in the next 3 days.

@owocki
Copy link
Contributor Author

owocki commented Dec 28, 2017

note: you may wish to rely on the github integration coded here #156

@gitcoinbot
Copy link
Member

This issue now has a funding of 0.13 ETH (89.98 USD) attached to it.

  • If you would like to work on this issue you can claim it here.
  • If you've completed this issue and want to claim the bounty you can do so here
  • Questions? Get help on the Gitcoin Slack
  • $9963.55 more Funded OSS Work Available at: https://gitcoin.co/explorer

@gitcoinbot
Copy link
Member

The funding of 0.13 ETH (89.98 USD) attached has been claimed by @usulix.

@usulix, please leave a comment to let the funder (@owocki) and the other parties involved your implementation plan. If you don't leave a comment, the funder may expire your claim at their discretion.

@usulix
Copy link

usulix commented Dec 29, 2017

@owocki

  • I have web setup on my local from working on design: waiting room quote while page is waiting for web3 updates #181
  • I have the new route and page added - currently adding it to dashboard... but I could see how it might be better suited to retail... lmk, please, if you want it there instead
  • I will add form fields per the new model
  • I was planning to check that attached wallet balance is 0 (but maybe that should check for almost 0 instead ?)
  • I will check 1 faucet per github on Github profile change in the form
  • I will add model
  • I will hook into the settings.SERVER_EMAIL and send email (plain text ok?)
  • and I will build the admin page to process the faucet transaction based upon a settings.FAUCET_AMOUNT... currently set to .003
  • should the admin form be a list with the ability to filter for fulfilled, unfulfilled, or all and a button to fulfill unfulfilled ?.... or just one page with the new request ? and if we do one page.. how would you like to navigate to other requests ?

Thanks
G

@owocki
Copy link
Contributor Author

owocki commented Dec 29, 2017

but maybe that should check for almost 0 instead

yes pls

plain text ok?
yes

should the admin form be a list with the ability to filter for fulfilled, unfulfilled, or all and a button to fulfill unfulfilled ?...

you can use the default django admin view for the list.. copying some of the patteresn from tdi/admin.py#WhitepaperAccessRequest might be good too

@usulix
Copy link

usulix commented Dec 29, 2017

@owocki
sounds great. will do.
re: "I have the new route and page added - currently adding it to dashboard... but I could see how it might be better suited to retail... lmk, please, if you want it there instead"
I am finding myself in need of slightly different errors for

{% include 'shared/no_metamask_error.html' %}
{% include 'shared/zero_balance_error.html' %}
{% include 'shared/unlock_metamask.html' %}

ie. for that error... "Thank you for your interest in receiving a faucet distribution, but you have more ether currently in your wallet than the distribution."

So, unless it is a problem, I am creating a new (ZF1 I would call it a module.. not sure about Django name for it) section under app with dashboard, marketing, retail.. etc called faucet... that way the views and models can be modular and contained there [while staying as DRY as possible, of course].. sound ok ?

@owocki
Copy link
Contributor Author

owocki commented Dec 29, 2017

yes that sounds right. you shouldnt need any of the shared/ partials for this view

@usulix
Copy link

usulix commented Dec 30, 2017

@owocki - I see comments in the model... should that be an optional field on the form for users to put in something like "I am going to claim issue #184" ?... or is it for admin notes at some point ?

@owocki
Copy link
Contributor Author

owocki commented Dec 30, 2017 via email

@usulix
Copy link

usulix commented Jan 1, 2018

@owocki ,
Hi and Happy New Year.
I wanted to give you an update on this.
I have everything done except funding the request from the admin panel. I just realized that the contrib.admin uses much more of a request->page->request->page method than something that will allow easier interactions with w3.

I will need to take a look at the client side setup and add that to the template in admin. I have obligations Tuesday but should be able to finish Wednesday.

Regards,
G

@owocki
Copy link
Contributor Author

owocki commented Jan 2, 2018

thanks for the update..

request->page->request->page

i wonder if we could get around this with some simple javascript.. just something simple that submits the tx to web3 and submits the HTML form after it has.

@usulix usulix mentioned this issue Jan 3, 2018
3 tasks
@vs77bb
Copy link
Contributor

vs77bb commented Jan 9, 2018

Howdy @usulix, I joined @owocki at Gitcoin and am checking in here... how goes it?

@owocki
Copy link
Contributor Author

owocki commented Jan 9, 2018

i think i need to review @usulix 's PR :)

@vs77bb
Copy link
Contributor

vs77bb commented Jan 17, 2018

@owocki Did you get to this? An exciting feature worth a small content piece, whenever ready - IMHO :)

@owocki
Copy link
Contributor Author

owocki commented Jan 17, 2018

yes i am waiting on @usulix to turnaround my comments on the PR

@usulix usulix mentioned this issue Jan 19, 2018
3 tasks
@owocki
Copy link
Contributor Author

owocki commented Jan 25, 2018

per @usulix message on slack.. he is super busy at work and needs some help getting this across the finish line.. i need to confirm with him, but i think yall should split the ETH. anyone want? @ethikz @thelostone-mc ?

@ethikz
Copy link
Contributor

ethikz commented Jan 25, 2018

I've added his repo as a remote and cloned it. Just trying to catch up on what's going. If @thelostone-mc gets to it before me then awesome, if not I'll let you know once I go through everything.

@usulix
Copy link

usulix commented Jan 26, 2018

@ethikz thanks. and any questions, I can probably field a couple. as far as I recall... it is basically just in need of

  1. change out the page markup for the ones provided on the other ticket Design: Faucet page #173 (comment)
  2. run the github user check through github login instead (and maybe create a user profile in gitcoin)
  3. tack on an email to the requester when admin funds the faucet request

@thelostone-mc
Copy link
Member

@ethikz this one is yours!
I'm helping out with the redeem/coin page and catching up on reading up solidity + crypto-economics!
Ping me if you hit a roadblock, I'll help out. I can put some time aside to help out ^_^

@ethikz
Copy link
Contributor

ethikz commented Jan 26, 2018

@usulix awesome! thanks for letting me know and saving me some more reading time lol. Hopefully, I won't have too many if any questions but I'll be sure to reach out if I do!

@thelostone-mc haha ok. I'll spend some time on it this weekend but will be traveling to multiple destinations for a bit so won't be able to really work on anything then.

@ethikz
Copy link
Contributor

ethikz commented Jan 26, 2018

@usulix so the page /faucet needs to match the mockups at #173 (comment)

Am I understanding that correctly?

@usulix
Copy link

usulix commented Jan 26, 2018

Yes, there are comps at https://github.com/gitcoinco/web/files/1599926/Gitcoin_Faucet.2.zip attached to that ticket

@ethikz
Copy link
Contributor

ethikz commented Jan 26, 2018

The comps are different than the pages so I wanted to make sure before I started making all the UI changes lol.

Thanks!

@usulix
Copy link

usulix commented Feb 1, 2018 via email

@ethikz
Copy link
Contributor

ethikz commented Feb 1, 2018

@usulix Are you on Gitcoin slack?

@usulix
Copy link

usulix commented Feb 1, 2018 via email

@ethikz
Copy link
Contributor

ethikz commented Feb 2, 2018

Oh ok, didn't find your username. So for sake of going back and forth can you just message me when you get on.

@owocki
Copy link
Contributor Author

owocki commented Feb 12, 2018

@vs77bb this might be a good one to promote via twitter to get folks to jump on it

@ethikz you still want it?

@vs77bb
Copy link
Contributor

vs77bb commented Feb 13, 2018

@owocki
Copy link
Contributor Author

owocki commented Feb 13, 2018

i moved this over to a new place => #407

once that scope is completed, i will pay out both bounties

@owocki owocki closed this as completed Feb 13, 2018
@gitcoinco gitcoinco deleted a comment from gitcoinbot Feb 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants