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

Claim vested COW for locked GNO #364

Closed
wants to merge 16 commits into from
Closed

Claim vested COW for locked GNO #364

wants to merge 16 commits into from

Conversation

anxolin
Copy link
Contributor

@anxolin anxolin commented Apr 4, 2022

Summary

This PR adds a section to the profile page for letting users claim vested COW tokens they received for locking GNO.

To Test

Open the page Profile

  • If the connected account is eligible for vested COW from locked GNO (all addresses listed here: https://dune.xyz/bh2smith/Locked-GNO-Snapshot) it should show a section COW vesting from locked GNO
  • The section should show the currently vested amount of tokens
  • Users that are not eligible should not see the section

Claim the vested COW

  • Click the Claim COW button, sign the transaction
  • A transaction shall be added to the pending list and the user shall be notified once it completes
  • The claim button should be disabled and show Successfully claimed
  • The vested amount field should update to show the balance that became vested since clicking the claim button

Background

To prevent a negative impact on page load performance, the merkle proof data for claiming the vested tokens is chunked and will be fetched lazily only when navigating to the profile page. The data can be found in this external repo: https://github.com/gnosis/locked-gno-cow-merkle-distro

Originally created by @jfschwarz in gnosis/cowswap#2599

@github-actions
Copy link
Contributor

github-actions bot commented Apr 4, 2022

CLA Assistant Lite:
Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


1 out of 2 committers have signed the CLA.
@jfschwarz
@lint-action
You can retrigger the CLA Action by commenting recheckcla in this Pull Request

@anxolin
Copy link
Contributor Author

anxolin commented Apr 4, 2022

@jfschwarz note we need to recreate this PR because we are migrating all repositories. I'll add to the slack chat some details

@github-actions
Copy link
Contributor

github-actions bot commented Apr 4, 2022

  • 🔭 GP Swap: CoW Protocol v2 Swap UI

@anxolin
Copy link
Contributor Author

anxolin commented Apr 4, 2022

Hi, @jfschwarz , as mentioned in the chat:

  • ABIs are merged, so I guess you will be able to rebase this PR and reduce drastically the number of changes
  • @elena-zh will need some way to test the claims. Can we deploy a test contract so we get some way to test it?
  • Let us know if the new repo or the re-creation of this PR cause you any troubles

@elena-zh
Copy link

elena-zh commented Apr 4, 2022

Hey @jfschwarz , I have verified the latest changes related to the gnosis/cowswap#2599 (comment) issue, and they LGTM!

The only thing is left, is to complete test scenario and run a successful claim transaction. For this, it would great is you can deploy a test contract in Rinkeby with test accounts with locked GNO.
If you need, I can list you several my accounts to include them into the test deployment.
Thank you!

@jfschwarz jfschwarz changed the title Locked gno claim Claim vested COW for locked GNO Apr 4, 2022
@jfschwarz
Copy link
Contributor

I have read the CLA Document and I hereby sign the CLA

@elena-zh
Copy link

elena-zh commented Apr 5, 2022

Hey @jfschwarz , @anxolin
If we are adding a MOO sound when swap vCow->cow transaction is mined (implemented in #365), should we add this sound for the claiming vested COW for locked GNO successful transaction?

@bh2smith
Copy link
Contributor

bh2smith commented Apr 9, 2022

Just wanted to point out that the dashboard won't display the amount of vested COW due to this. That computation was performed using an aggregation of the total amounts of "locked" GNO on each network and the 50M was distributed as each accounts proportion of the total. I could probably put together a query that shows this if anyone would like.

@elena-zh
Copy link

Hey @jfschwarz , @anxolin If we are adding a MOO sound when swap vCow->cow transaction is mined (implemented in #365), should we add this sound for the claiming vested COW for locked GNO successful transaction?

We have added 'View Contract' and 'Copy contract' buttons to the cards. So, besides the Moo sound (if we decide to use it) it would be nice to add these buttons to the 'Claim COW form locked GNO' card as well
image

@nenadV91 nenadV91 mentioned this pull request Apr 13, 2022
@nenadV91 nenadV91 closed this Apr 26, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Apr 26, 2022
@nenadV91
Copy link
Contributor

Closed in favor of #405

@fairlighteth fairlighteth deleted the locked-gno-claim branch July 4, 2024 15:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants