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

Feature: Add getters in exchange #71

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Feature: Add getters in exchange #71

wants to merge 1 commit into from

Conversation

jinyang1994
Copy link

Background

Sometimes you need to use FirstTradedTimestamp, LastSettledTimestamp, and LastFundingGrowthGlobal for statistics. Although I can find them through contract events, I think it would be very convenient if you can use some getters, so I added the following functions:

  • Exchange.getFirstTradedTimestamp
  • Exchange.getLastSettledTimestamp
  • Exchange.getLastFundingGrowthGlobal

PR Reminders

Be ware of the followings

  • implement deployment script for your changes in deployment repo
  • add verification in hardhat simulation(000-prepare-simulation-check, 902-newMarket-check or 903-simulation-check) and system test(901-system-test) in deployment repo
  • update change log

  1. Contract: make sure the code follows our convention, ex: naming, explicit returns, etc.; if uncertain, discuss with others

  2. Test: make sure tests can cover most normal and edge cases; if not, open follow-up tickets. Also, look out for failed tests and fix them!

  3. CHANGELOG.md: update when external interfaces are changed

  4. Workflow:

    • Github: assign the pr to yourself; if pairing, can merge directly; else, assign someone to help review
    • Asana: assign the corresponding ticket to yourself and leave the pr link on it for easier follow-ups
    • Discord: if someone is mentioned in this pr, tag on Discord

@jinyang1994
Copy link
Author

@42bchen @tailingchen Can you review it? Thx

@jinyang1994 jinyang1994 closed this by deleting the head repository Feb 27, 2023
@jinyang1994 jinyang1994 reopened this Mar 8, 2023
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.

1 participant