go-ethereum/core/txpool
Daniel Liu ad9003c41e
eth/tracers: live chain tracing with hooks #29189 (#1352)
Here we add a Go API for running tracing plugins within the main block import process.

As an advanced user of geth, you can now create a Go file in eth/tracers/live/, and within
that file register your custom tracer implementation. Then recompile geth and select your tracer
on the command line. Hooks defined in the tracer will run whenever a block is processed.

The hook system is defined in package core/tracing. It uses a struct with callbacks, instead of
requiring an interface, for several reasons:

- We plan to keep this API stable long-term. The core/tracing hook API does not depend on
  on deep geth internals.
- There are a lot of hooks, and tracers will only need some of them. Using a struct allows you
   to implement only the hooks you want to actually use.

All existing tracers in eth/tracers/native have been rewritten to use the new hook system.

This change breaks compatibility with the vm.EVMLogger interface that we used to have.
If you are a user of vm.EVMLogger, please migrate to core/tracing, and sorry for breaking
your stuff. But we just couldn't have both the old and new tracing APIs coexist in the EVM.

---------

Co-authored-by: Sina M <1591639+s1na@users.noreply.github.com>
Co-authored-by: Matthieu Vachon <matthieu.o.vachon@gmail.com>
Co-authored-by: Delweng <delweng@gmail.com>
Co-authored-by: Martin HS <martin@swende.se>
2025-09-09 17:30:56 +08:00
..
journal.go all: use common.FileExist for checking file existence #24748 (#1212) 2025-07-11 10:42:51 +08:00
lending_pool.go common: refactor constants 2025-02-17 09:13:40 +08:00
lending_pool_test.go all: replace t.Log(); t.FailNow() with t.Fatal() (#19849) 2025-01-24 16:18:29 +08:00
lending_tx_journal.go all: use common.FileExist for checking file existence #24748 (#1212) 2025-07-11 10:42:51 +08:00
lending_tx_list.go all: refactor txpool into it's own package in prep for 4844 (#26038) 2024-11-01 11:36:53 +08:00
list.go core, internal/ethapi: improve function IsSpecialTransaction 2025-02-20 12:48:17 +08:00
list_test.go all: refactor txpool into it's own package in prep for 4844 (#26038) 2024-11-01 11:36:53 +08:00
noncer.go all: refactor txpool into it's own package in prep for 4844 (#26038) 2024-11-01 11:36:53 +08:00
order_pool.go all: use big.Sign to compare with zero #29490 (#1387) 2025-08-28 18:56:39 +08:00
order_pool_test.go all: refactor txpool into it's own package in prep for 4844 (#26038) 2024-11-01 11:36:53 +08:00
order_tx_journal.go all: use common.FileExist for checking file existence #24748 (#1212) 2025-07-11 10:42:51 +08:00
order_tx_list.go all: refactor txpool into it's own package in prep for 4844 (#26038) 2024-11-01 11:36:53 +08:00
txpool.go core/txpool: accept non-local transaction with zero tip (#950) 2025-04-21 16:11:43 +08:00
txpool_test.go eth/tracers: live chain tracing with hooks #29189 (#1352) 2025-09-09 17:30:56 +08:00