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

Price discovery restrictions #292

Merged
merged 13 commits into from
Mar 2, 2022
Merged

Conversation

dorin-iancu
Copy link
Contributor

There are now multiple phases during the price discovery period:

  • phase 1: Anyone can deposit and withdraw any amounts
  • phase 2: Anyone can deposit, but withdrawals come with a linear increasing penalty
  • phase 3: Deposits are not allowed. Withdrawals are allowed with a fixed penalty
  • phase 4: Adding liquidity to the LP and allowing users to redeem after a certain number of epochs

Accumulated penalties are given as rewards in the redeem period, according to the percentage of the total pool the user owns. (i.e. if the user owns 50% of the initial liquidity, they will receive 50% of the accumulated penalties for that specific token)

@dorin-iancu dorin-iancu marked this pull request as draft February 11, 2022 15:08
@sasurobert sasurobert self-requested a review February 14, 2022 12:59
sasurobert
sasurobert previously approved these changes Feb 17, 2022
Copy link
Contributor

@sasurobert sasurobert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to offer some rewards as well for those who lock their LPs. Add a depositRewards endpoint which can be called by a whitelisted address and with a given token, until unlock period starts. And when users are unlocking they should get their fair share of rewards.

@github-actions
Copy link

github-actions bot commented Mar 1, 2022

Contract file size comparison (bytes) - from a1bea1d to bfcbec4

Contract Previous Current Difference Percentage
dex/farm 35158 35158 +0 +0.00% ✓
dex/pair 34115 34115 +0 +0.00% ✓
dex/router 24369 24369 +0 +0.00% ✓
locked-asset/distribution 15985 15985 +0 +0.00% ✓
locked-asset/factory 33052 33052 +0 +0.00% ✓
locked-asset/proxy_dex 44294 44294 +0 +0.00% ✓

@dorin-iancu dorin-iancu marked this pull request as ready for review March 1, 2022 15:17
@dorin-iancu dorin-iancu merged commit 4c83f91 into main Mar 2, 2022
@dorin-iancu dorin-iancu deleted the price-discovery-restrictions branch March 2, 2022 08:21
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

Successfully merging this pull request may close these issues.

3 participants