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

Inconsistent base_fee type #2181

Open
Tracked by #769
Wodann opened this issue Mar 11, 2025 · 1 comment
Open
Tracked by #769

Inconsistent base_fee type #2181

Wodann opened this issue Mar 11, 2025 · 1 comment

Comments

@Wodann
Copy link
Contributor

Wodann commented Mar 11, 2025

I updated to the latest alloy versions and ran into an inconsistency while updating my code.

Based on this discussion it seems that it was decided to update block header gas_limit and gas_used to u64.

However, in that change, the base_fee type of calc_next_block_base_fee and its return type were also updated from u128 to u64, requiring truncation of the base_fee argument at call sites.

From a safety perspective, this seems like it might have been an erroneous change.

If you agree, I'm happy to submit a PR with the fix.

@mattsse
Copy link
Member

mattsse commented Mar 11, 2025

why would a base_fee of calc_next_block_base_fee be beneficial?

I think we still have some things as u128 but I'd rather settle on u64

what's the callsite that hase basefee u128?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

2 participants