alloy-rs / alloy-rs/alloy

[Bug] SendTransaction Failed on BSC due to Legacy TxType

Abierto
#3,775 1 comentario 0 reacciones 0 asignados Ver en GitHub
bug
Lenguaje dominante
Rust
Estrellas
1.3k
Forks
668
Merge medio
2 d 1 h
PR fusionados (30 d)
29

Descripción

### Component

provider, pubsub

### What version of Alloy are you on?

1.6.1

### Operating System

macOS (Apple Silicon)

### Describe the bug

In `provider/trait.rs`, function `estimate_eip1559_fees_with`, there is a condition to check if the latest block even has a base fee/supports EIP1559, it works for all evm chains which support eip1559 but fails on **Binance Smart Chain**. For BSC, although it does include `baseFeePerGas` in block headers and its RPC likely succeeds on EIP-1559 fee estimation calls, but it doesn't actually process EIP-1559 transaction types. If you call RPC something like "eth_getBlockByNumber", it returns a header that includes `baseFeePerGas` with "0x0" instead of None. So the condition check might fail with BSC, a small fix that additionally checks whether `baseFeePerGas` is non-zero might work well.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.