-
Notifications
You must be signed in to change notification settings - Fork 3
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
Chore) update entry point names #162
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
reduced some logic to use less steps updated storage var names for clarity
-removed vault_manager -updated calls to new round interface -changed event to StashWithdrawn (instead of QueuedLiquidityCollected)
-fixed member names for clarity
- change update bid to taking in price increase, amount cannot be altered now - update account bid nonce to u64 to match tree nonce - made auction start event also emit starting liquidity - changed bid accepted event to bid placed event - bid update event emits price increase - made auction end event also emit unsold liquidity - dropped total payout from round settled event -
also store vault's and accounts' queued liquidity in the same mapping
* Edits * Remove Outputs * Update gitignore * Update withdrawal premiums logic * Fuzzing
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
OptionRound Updates
get_bid_tree_nonce()
update_bid(bid_id, price_increase)
only increases the price of a bid by price_increase. Users can no longer increase their bid amountChanged
starting_liquidity()
->get_starting_liquidity()
total_premiums()
->get_total_premium()
unsold_liquidity()
->get_unsold_liquidity()
clearing_price()
->get_clearing_price()
total_payout()
->get_total_payout()
vault_address()
->get_vault_address()
total_options_sold()
->get_options_sold()
total_options_available()
->get_options_available()
get_refundable_balance_for()
->get_account_refundable_balance()
get_mintable_options_for()
->get_account_mintable_options()
get_total_option_balance_for()
->get_account_total_options()
get_payout_balance_for()
->get_account_payout_balance()
get_bidding_nonce_for()
->get_account_bid_nonce()
get_bids_for()
->get_account_bids()
settle_option_round()
->settle_round()
Storage Var
bidder_nonces
->account_bid_nonce
Events
BidAccepted
->BidPlaced
{total_options_available}
->{starting_liquidity, options_available}
{clearing_price, total_options_sold}
->{options_sold, clearing_price, unsold_liquidity}
{total_payout, payout_per_option, settlement_price}
->{settlement_price, payout_per_option}
{account, nonce, amount, price}
->{account, bid_id, amount, price, bid_tree_nonce_now}
-> {account, bid_id, price_increase, bid_tree_nonce_now}
{account, amount}
->{account, minted_amount}
{account, amount}
->{account, refunded_amount}
{account, num_options, amount}
->{account, number_of_options, exercised_amount}
Structs
{id, nonce, owner, amount, price}
->{bid_id, owner, amount, price, tree_nonce}
Vault Updates
vault_manager()
get_lp_starting_balance()
vault_manager
,Changes
vault_type()
->get_vault_type()
get_market_aggregator()
->get_market_aggregator_address()
eth_address()
->get_eth_address()
current_round_id()
->get_current_round_id()
get_total_balance()
->get_vault_total_balance()
get_total_locked_balance()
->get_vault_locked_balance()
get_total_unlocked_balance()
->get_vault_unlocked_balance()
get_total_stashed_balance()
->get_vault_stashed_balance()
get_total_queued_balance()
->get_vault_queued_bps()
->
get_account_total_balance()`get_lp_locked_balance()
->get_account_locked_balance()
get_lp_unlocked_balance()
->get_account_unlocked_balance()
get_lp_stashed_balance()
->get_account_stashed_balance()
get_lp_queued_bps()
->get_account_queued_bps()
deposit_liquidity()
->deposit()
withdraw_liquidity()
->withdraw()
claim_queued_liquidity()
->withdraw_stash()
settle_option_round()
->settle_round()
Storage Vars
market_aggregator
->market_aggregator_address
total_locked_balance
->vault_locked_balance
total_unlocked_balance
->vault_unlocked_balance
total_stashed_balance
->vault_stashed_balance
premiums_moved
->is_premiums_moved
withdraw_checkpoints
->position_checkpoints
queue_checkpoints
->stash_checkpoints
round_queued_liquidity
&user_queued_liquidity
into a singlequeued_liquidity
mapping. Instead of a mapping forround_id -> total_amount
&(account, round_id) -> amount
, we can just get the total for each round at slot(vault_address, round_id) -> total_amount
& the account's total at slot(account_address, round_id) -> amount
Events
QueuedLiquidityCollected
->StashWithdrawn
{account, bps, account_queued_amount_now, vault_queued_amount_now}
->{account, bps, account_queued_liquidity_now, vault_queued_liquidity_now}