Skip to content

fix: ensure maxPriorityFeePerGas does not exceed maxFeePerGas in DynamicEIP1559GasProvider#2264

Open
Dev10-sys wants to merge 3 commits intoLFDT-web3j:mainfrom
Dev10-sys:fix/eip1559-priority-fee-overflow-clean
Open

fix: ensure maxPriorityFeePerGas does not exceed maxFeePerGas in DynamicEIP1559GasProvider#2264
Dev10-sys wants to merge 3 commits intoLFDT-web3j:mainfrom
Dev10-sys:fix/eip1559-priority-fee-overflow-clean

Conversation

@Dev10-sys
Copy link
Copy Markdown
Contributor

This PR fixes an edge case where maxPriorityFeePerGas could exceed maxFeePerGas due to inconsistent RPC results.

The fix ensures that maxFeePerGas is always greater than or equal to maxPriorityFeePerGas by introducing a high-water mark for the priority fee during calculation.

A unit test is added to cover this scenario and verify the fix.

Fixes #2225

Dev10-sys added a commit to Dev10-sys/web3j that referenced this pull request Apr 22, 2026
…der (LFDT-web3j#2264)

Signed-off-by: Dev10-sys <kalpanagola9897@gmail.com>
…micEIP1559GasProvider

Signed-off-by: Dev10-sys <kalpanagola9897@gmail.com>
…der (LFDT-web3j#2264)

Signed-off-by: Dev10-sys <kalpanagola9897@gmail.com>
@Dev10-sys Dev10-sys force-pushed the fix/eip1559-priority-fee-overflow-clean branch from eaa1ed2 to d87cd89 Compare April 23, 2026 21:13
Signed-off-by: Dev10-sys <dev10.sys@gmail.com>
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.

DynamicEIP1559GasProvider: max priority fee per gas higher than max fee per gas

1 participant