go-ethereum/eth/tracers/logger
Matthieu Vachon 32c14945da Full OnGasConsumed loop and added GasChangeReason
With this change, the full gas loop of a transaction can be tracked going from initial balance (`gasLimit`) back down to 0.

I validated on my regression test suite that those conditions applied to all transactions I have:
- First `OnGasConsumed` is always going from 0 -> `trx.gasLimit`
- Last `OnGasConsumed` "new value" is always 0
- trx.gasLimit - last balance of last `OnGasConsumed` is equal to `trx.gasUsed`

The addition of `reason` make it possible for a logger to filter out unwanted signal, for example one could want to drop all OpCode related gas change and only cares about "transaction" level. The reason is also a good thing for visibility and for creating powerful debug tools for Ethereum transaction execution.
2023-08-02 09:16:45 -04:00
..
access_list_tracer.go Full OnGasConsumed loop and added GasChangeReason 2023-08-02 09:16:45 -04:00
gen_structlog.go eth/tracers/logger: use omitempty to reduce log bloat (#24547) 2022-03-29 22:36:55 +02:00
logger.go Full OnGasConsumed loop and added GasChangeReason 2023-08-02 09:16:45 -04:00
logger_json.go Full OnGasConsumed loop and added GasChangeReason 2023-08-02 09:16:45 -04:00
logger_test.go Capture balance reason (#12) 2023-07-26 10:49:04 +02:00