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

auth-server: record metrics for output net of gas and fees #94

Merged
merged 1 commit into from
Jan 21, 2025

Conversation

sehyunc
Copy link
Contributor

@sehyunc sehyunc commented Jan 21, 2025

Purpose

This PR records metrics net of both gas costs and fees.

Testing

  • Tested locally
  • Test in testnet

@sehyunc sehyunc changed the base branch from main to sehyun/fee-costs January 21, 2025 08:04
@sehyunc sehyunc requested a review from joeykraut January 21, 2025 08:04
Comment on lines 74 to 79
let diff_ratio = (our_output_value_net_of_gas - source_output_value_net_of_gas)
/ source_output_value_net_of_gas;
let bps_diff = diff_ratio * DECIMAL_TO_BPS;

bps_diff as i32
Copy link
Member

Choose a reason for hiding this comment

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

same as the last PR, this should probably be an f64 computation. Also, since it shows up so much, might be worth refactoring into a helper

@sehyunc sehyunc force-pushed the sehyun/fee-costs branch 2 times, most recently from bf3e05f to ef6fe5b Compare January 21, 2025 19:00
@sehyunc sehyunc force-pushed the sehyun/net-costs branch 3 times, most recently from 62c3d4a to dc2e180 Compare January 21, 2025 19:04
Base automatically changed from sehyun/fee-costs to main January 21, 2025 19:04
@sehyunc sehyunc merged commit 24b1de5 into main Jan 21, 2025
3 checks passed
@sehyunc sehyunc deleted the sehyun/net-costs branch January 21, 2025 19:08
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.

2 participants