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

feat: fees/priority endpoint #984

Open
wants to merge 19 commits into
base: release/galactica
Choose a base branch
from

Conversation

freemanzMrojo
Copy link
Member

@freemanzMrojo freemanzMrojo commented Feb 20, 2025

Description

This endpoint is a version of eth_maxPriorityFeePerGas.

Interface-wise is the same, and the parameters are based on go-ethereum except for the max priority fee cap (500 gwei in Eth, we do not have a reference figure yet). The other difference is that all the params are internal and non-configurable (in geth they use also flags, we can do the same but I prefer to comment it over the PR).

Re-uses the cache logic of the other fees endpoint so the common cache is built by any of these endpoints.

Added a new integration test for this endpoint, further testing will be done as part of the follow-up ticket regarding parameters. Checked though that the priority fees array is built as expected.

Closes https://github.com/vechain/protocol-board-repo/issues/390

@codecov-commenter
Copy link

codecov-commenter commented Feb 20, 2025

Codecov Report

Attention: Patch coverage is 75.55556% with 22 lines in your changes missing coverage. Please review.

Project coverage is 62.16%. Comparing base (1b887cd) to head (ed463d5).

Files with missing lines Patch % Lines
api/fees/data.go 71.64% 15 Missing and 4 partials ⚠️
api/fees/fees.go 86.95% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@                  Coverage Diff                  @@
##           release/galactica     #984      +/-   ##
=====================================================
+ Coverage              62.14%   62.16%   +0.02%     
=====================================================
  Files                    226      226              
  Lines                  23498    23570      +72     
=====================================================
+ Hits                   14603    14653      +50     
- Misses                  7761     7779      +18     
- Partials                1134     1138       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@freemanzMrojo freemanzMrojo marked this pull request as ready for review February 20, 2025 11:51
@freemanzMrojo freemanzMrojo requested a review from a team as a code owner February 20, 2025 11:51
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