replayer

package
v1.0.0-rc.12-debug Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TracerConfig = `{"onlyTopCall":true}`
	TracerName   = "callTracer"
)

Variables

View Source
var NopTracer = &nopTracer{}

Functions

func DefaultCallTracer

func DefaultCallTracer() (*tracers.Tracer, error)

func NewSafeTxTracer

func NewSafeTxTracer(ct *CallTracerCollector) *tracers.Tracer

Types

type BlocksProvider

type BlocksProvider struct {
	// contains filtered or unexported fields
}

func NewBlocksProvider

func NewBlocksProvider(
	blocks storage.BlockIndexer,
	chainID flowGo.ChainID,
	tracer *tracers.Tracer,
) *BlocksProvider

func (*BlocksProvider) GetSnapshotAt

func (bp *BlocksProvider) GetSnapshotAt(height uint64) (
	evmTypes.BlockSnapshot,
	error,
)

func (*BlocksProvider) OnBlockReceived

func (bp *BlocksProvider) OnBlockReceived(block *models.Block) error

type CallTracerCollector

type CallTracerCollector struct {
	// contains filtered or unexported fields
}

func NewCallTracerCollector

func NewCallTracerCollector(logger zerolog.Logger) (
	*CallTracerCollector,
	error,
)

func (*CallTracerCollector) Collect

func (ct *CallTracerCollector) Collect(txID common.Hash) (json.RawMessage, error)

func (*CallTracerCollector) ResetTracer

func (t *CallTracerCollector) ResetTracer() error

func (*CallTracerCollector) TxTracer

func (t *CallTracerCollector) TxTracer() *tracers.Tracer

type Config

type Config struct {
	ChainID             flow.ChainID
	RootAddr            flow.Address
	CallTracerCollector EVMTracer
	ValidateResults     bool
}

type EVMTracer

type EVMTracer interface {
	TxTracer() *tracers.Tracer
	ResetTracer() error
	Collect(txID common.Hash) (json.RawMessage, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL