Skip to content

Commit

Permalink
rpcdaemon: Don't set miner (#13795)
Browse files Browse the repository at this point in the history
Fixes incorrect patch for #12690

See:
#12690 (comment)

```
➜  curl --request POST \
  -s --url http://127.0.0.1:8545/ \
  --header 'Content-Type: application/json' \
  --data '{
        "method": "eth_getBlockByHash",
        "params": [
                "latest",
                false
        ],
        "id": 1,
        "jsonrpc": "2.0"
}' | jq '.result.miner'
"0x0000000000000000000000000000000000000000"
➜  curl --request POST \
  -s --url http://127.0.0.1:8545/ \
  --header 'Content-Type: application/json' \
  --data '{
        "method": "eth_getBlockByNumber",
        "params": [
                "latest",
                false
        ],
        "id": 1,
        "jsonrpc": "2.0"
}' | jq '.result.miner'
"0x0000000000000000000000000000000000000000"
```
  • Loading branch information
shohamc1 authored Feb 13, 2025
1 parent c68a930 commit 702a0d8
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions turbo/jsonrpc/eth_block.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ import (
"github.com/erigontech/erigon/core/state"
"github.com/erigontech/erigon/core/types"
"github.com/erigontech/erigon/core/vm"
"github.com/erigontech/erigon/polygon/bor/borcfg"
bortypes "github.com/erigontech/erigon/polygon/bor/types"
"github.com/erigontech/erigon/rpc"
"github.com/erigontech/erigon/turbo/adapter/ethapi"
Expand Down Expand Up @@ -260,11 +259,6 @@ func (api *APIImpl) GetBlockByNumber(ctx context.Context, number rpc.BlockNumber
}
}

if chainConfig.Bor != nil {
borConfig := chainConfig.Bor.(*borcfg.BorConfig)
response["miner"], _ = ecrecover(b.Header(), borConfig)
}

return response, err
}

Expand Down Expand Up @@ -331,11 +325,6 @@ func (api *APIImpl) GetBlockByHash(ctx context.Context, numberOrHash rpc.BlockNu
}
}

if chainConfig.Bor != nil {
borConfig := chainConfig.Bor.(*borcfg.BorConfig)
response["miner"], _ = ecrecover(block.Header(), borConfig)
}

return response, err
}

Expand Down

0 comments on commit 702a0d8

Please sign in to comment.