debug_tx

package
v0.51.2 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2026 License: AGPL-3.0 Imports: 13 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cmd = &cobra.Command{
	Use:   "debug-tx",
	Short: "debug a transaction",
	Run:   run,
}

Functions

func FetchBlockHeader added in v0.49.0

func FetchBlockHeader(
	ctx context.Context,
	blockID flow.Identifier,
	flowClient *client.Client,
) (header *flow.Header)

func FetchBlockTransactions added in v0.49.0

func FetchBlockTransactions(
	ctx context.Context,
	blockID flow.Identifier,
	flowClient *client.Client,
) []*sdk.Transaction

func NewBlockSnapshot added in v0.49.0

func NewBlockSnapshot(
	remoteClient debug.RemoteClient,
	blockHeader *flow.Header,
) *debug.CachingStorageSnapshot

func RunBlock added in v0.49.0

func RunBlock(
	blockSnapshot debug.UpdatableStorageSnapshot,
	blockHeader *flow.Header,
	blockTransactions []*sdk.Transaction,
	debuggedTxID flow.Identifier,
	chain flow.Chain,
	wrapTxSnapshot func(blockTxID flow.Identifier, snapshot debug.UpdatableStorageSnapshot) debug.UpdatableStorageSnapshot,
	newSpanExporter func(blockTxID flow.Identifier) otelTrace.SpanExporter,
	computeLimit uint64,
	additionalFVMOptions []fvm.Option,
) (
	results []debug.Result,
)

func RunSingleTransaction added in v0.49.0

func RunSingleTransaction(
	ctx context.Context,
	remoteClient debug.RemoteClient,
	txID flow.Identifier,
	flowClient *client.Client,
	chain flow.Chain,
	spanExporter otelTrace.SpanExporter,
	computeLimit uint64,
) debug.Result

func RunTransaction added in v0.49.0

func RunTransaction(
	tx *sdk.Transaction,
	snapshot debug.StorageSnapshot,
	header *flow.Header,
	chain flow.Chain,
	spanExporter otelTrace.SpanExporter,
	computeLimit uint64,
	additionalFVMOptions []fvm.Option,
) debug.Result

func SubscribeBlockHeadersFromLatest added in v0.49.0

func SubscribeBlockHeadersFromLatest(
	ctx context.Context,
	flowClient *client.Client,
	blockStatus flow.BlockStatus,
) (get func() (*flow.Header, error))

func SubscribeBlockHeadersFromStartBlockID added in v0.49.0

func SubscribeBlockHeadersFromStartBlockID(
	ctx context.Context,
	flowClient *client.Client,
	startBlockID flow.Identifier,
	blockStatus flow.BlockStatus,
) (get func() (*flow.Header, error))

Types

type BlockHashEntropyProvider added in v0.49.0

type BlockHashEntropyProvider struct {
	BlockHash flow.Identifier
}

BlockHashEntropyProvider implements environment.EntropyProvider which provides a source of entropy to fvm context (required for Cadence's randomness), by using the given block hash.

func (BlockHashEntropyProvider) RandomSource added in v0.49.0

func (p BlockHashEntropyProvider) RandomSource() ([]byte, error)

Jump to

Keyboard shortcuts

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