flashbots / flashbots/relayscan

Displaying incorrect subsidy amounts

Open
#68 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
94
Forks
17
PR merge metrics
No merged PRs in 30d

Description

Relayscan shows incorrect subsidy amounts in several cases -- in particular when there are outgoing transfers from the builder coinbase.

Currently, relayscan uses a [very simple logic](https://github.com/flashbots/relayscan/blob/3aa5172895ddcbd1342aa8e5914ca4e5f69df07d/database/database.go#L173-L175):
- `coinbase_diff > 0`: profit
- `coinbase_diff < 0`: subsidy

There are multiple reasons outgoing transfers happen, include sending accumulated funds to a cold storage, refilling the bid adjustment wallet, or sending out refund txs. The first two (cold storage + bid adjustment top-up) should not be included in the builder balance, but the last should.

The best solution seems to be:
- keep a list of accounts that we know a builder owns (i.e. bid adjustments and multisig accounts)
- when going over the block txs, only include in `coinbase_diff` if it's not part of that list

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.