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

BOUNTY: Officiality checker (web3.js) #10

Closed
Dexaran opened this issue Jun 1, 2018 · 19 comments
Closed

BOUNTY: Officiality checker (web3.js) #10

Dexaran opened this issue Jun 1, 2018 · 19 comments
Labels
accepted This proposal is accepted by the Callisto Team. You will receive a reward for the implementation.

Comments

@Dexaran
Copy link
Member

Dexaran commented Jun 1, 2018

Proposal

The Callisto team allocates 12,000 CLO as a bounty for the implementation of "Officiality Checker" service UI.
"Officiality Checker is based on ECIP93 and Media Resources Registry smart-contract.

Description

Officiality Checker service must be an open source web application. It may be (1) a standalone web page OR (2) a separate tab at ClassicEtherWallet.

The main purpose of this application is to allow an average user to check whether a certain media resource is considered "official" at Callisto or not.

Officiality checker UI must have:

  • Input text field
  • "CHECK" button

A user should input a link to the media resource into the text field and click the "CHECK" button to perform the check.

After the user has clicked the button, Officiality Checker must invoke the is_official() function of the Media Registry contract to verify the inputted link. If the contract has returned true then the Officiality Checker must display a message that the media resource IS official. Otherwise, the Officiality Checker must display a warning message that the media resource is NOT official for Callisto.

Media Registry contract is currently deployed at Callisto network at 0xf6f29e5ba51171c4ef4997bd0208c7e9bc5d5eda address.

Bounty

One time payment: 12,000 CLO.

@Dexaran Dexaran added the accepted This proposal is accepted by the Callisto Team. You will receive a reward for the implementation. label Jun 1, 2018
@yuriy77k
Copy link

yuriy77k commented Jun 1, 2018

time to implement; 2 days

@Dexaran
Copy link
Member Author

Dexaran commented Jun 1, 2018

@yuriy77k alright.

@oritwoen
Copy link

oritwoen commented Jun 1, 2018

How does the "winner" choice be based?

  1. Reservation, i.e. yuriy77k who has applied for exclusivity for this job?
  2. First come first served. So if someone does a job first, do not matter what other people do?
  3. Choosing the best job at a given time from all those who work?

@Dexaran Dexaran added the in-progress This proposal is currently at implementation stage. label Jun 1, 2018
@Dexaran
Copy link
Member Author

Dexaran commented Jun 1, 2018

@Redni
The winner will be decided by Callisto Team.
If there are several candidates, we will evaluate the quality of each solution and pay for the best one.

You can still pick the issue, as long as the label accepted is here.

@yuriy77k
Copy link

yuriy77k commented Jun 1, 2018

This is standalone version.
https://github.com/yuriy77k/Officiality-checker-web3.js-

@Dexaran
Copy link
Member Author

Dexaran commented Jun 1, 2018

The results of the bounty will be evaluated at 5, Jun 2018.
Please, submit your contributions before this date.

@oritwoen
Copy link

oritwoen commented Jun 4, 2018

I will present my version in a few hours. I do not know if I will manage to midnight so I inform you not to miss me if I'm late for an hour or two :)

@yuriy77k
Copy link

yuriy77k commented Jun 4, 2018

ClassicEtherWallet tab version added:
https://github.com/yuriy77k/Officiality-checker-web3.js-

@oritwoen
Copy link

oritwoen commented Jun 4, 2018

Github: https://github.com/redni/officiality.checker
Demo: https://oad.earth/inder/checker/

Validation
Responsiveness
Deep checking, links of type

#10
https://twitter.com/CallistoSupport/status/1003275394580140032

will be considered true. My script checks all address possibilities.

@Dexaran
Copy link
Member Author

Dexaran commented Jun 5, 2018

@Redni yeah, deep checking is cool.
However, subdomains are not considered true. For example https://callisto.network/SOMETHING/ is considered official, but https://SOMETHING.callisto.network/ is not (but we own the domain callisto.network).

Analogue: https://mobile.twitter.com/CallistoSupport/status/1003275394580140032 is not valid.

@oritwoen
Copy link

oritwoen commented Jun 5, 2018

@Dexaran I did not even think about it, thanks! I added the amendment to the source and updated the demo. Subdomains should now be qualified correctly.

oritwoen/officiality.checker@efa5cfa

@yuriy77k
Copy link

yuriy77k commented Jun 5, 2018

standalone demo: http://cew.vizbe.ru/standalone/
CEW tab demo: http://cew.vizbe.ru/
(Tab will appear only if selected CLO network)

@yuriy77k
Copy link

yuriy77k commented Jun 5, 2018

Since, in the smart contract, links are added not normalized, it may cause misunderstood.
For example: https://twitter.com/CallistoSupport - will return "true", but https://twitter.com/callistosupport - will return "false".
I recommend create the rules for links (for example, only in lower case) and use them when adding and checking.

@oritwoen
Copy link

oritwoen commented Jun 5, 2018

It's best to add links without beginning (https://, http://) and endless (slash /) and lowercase to the contract. So, type

callisto.network
twitter.com/callistosupport

instead of

https://callisto.network/
https://twitter.com/CallistoSupport

then such a checker will be able to check each link if you add a simple rule to the code.

Now is the case that you need to cut the address to delete the beginning and end and then 4 rules to correctly get the result and it does not work for links like https://twitter.com/Callistosupport https://twitter.com/callistosupport, etc.

contract.is_official("http://" + path) === true ||
contract.is_official("https://" + path) === true ||
contract.is_official("http://" + path + '/') === true ||
contract.is_official("https://" + path + '/') === true

Because https://callisto.network/ return true and http://callisto.network/ returns false.

@yuriy77k
Copy link

yuriy77k commented Jun 5, 2018

Officiality Checker updated for more flexible checking.
https://github.com/yuriy77k/Officiality-checker-web3.js-

standalone demo: http://cew.vizbe.ru/standalone/
CEW tab demo: http://cew.vizbe.ru/
(Tab will appear only if selected CLO network)

@Dexaran
Copy link
Member Author

Dexaran commented Jun 5, 2018

We discussed this bounty-proposal in our team.
It was decided to launch https://callisto.network/check service based on @Redni's standalone version and merge @yuriy77k's implementation into CEW.

As the result, we will reward both of you.

I'd like to ask you to provide your CLO addresses below.

@yuriy77k
Copy link

yuriy77k commented Jun 5, 2018

Thank you very much.
My CLO address: 0x85F381026f67d5d5F185643cE3139A46Ae1a7708

@oritwoen
Copy link

oritwoen commented Jun 5, 2018

Thank you! :) In case of any problems, please report, I will apply the corrections. I will also monitor changes in your contract in order to keep the code updated on a regular basis :)

Address: 0x21ddA703d5c53cbDd8BfC3f2a2a7e3df21da5437

@Dexaran Dexaran closed this as completed Jun 6, 2018
@Dexaran Dexaran removed the in-progress This proposal is currently at implementation stage. label Jun 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted This proposal is accepted by the Callisto Team. You will receive a reward for the implementation.
Projects
None yet
Development

No branches or pull requests

3 participants