fix: update gas_limit variable type from u32 to u64 #62
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.
Motivation
When collecting transactions data from other EVM chains (BSC) there were some transactions that had a gas_limit greater than u32::MAX() which caused an integer overflow error.
In BSC there are transactions that use i64::MAX as the gas limit. This is most commonly seen in the last transaction of the block where the validator deposits to the validator set.
Example here: https://bscscan.com/tx/0x7dcda3c9b1ced4c01f5634a88ab72a34ffc3d3f4c1fe1aed88c2fca0d0a34efd
Solution
Update data type for gas_limit variable for transactions from u32 to u64.
PR Checklist