Crate signet_bundle

Source
Expand description

Signet Bundle Library

Contains the SignetCallBundle and SignetEthBundle type, and utilities related to creating and simulating Signet bundles.

§Bundles

The SignetCallBundle and SignetEthBundle types are used to simulate transaction bundles in different ways. The SignetBundleDriver type drives a SignetCallBundle to completion and generates a SignetCallBundleResponse. This is used primarily by the RPC server to serve signet_callBundle requests. The response includes the standard flashbots-style response information, as well as a description of the fills necessary to make the bundle valid on Signet.

The SignetEthBundle type is used to simulate transaction bundles while building blocks. It is used primarily by builders and relays. The SignetEthBundleDriver drives a SignetEthBundle to completion and enforces bundle rules. When used in a block builder, it will ensure that the bundle is valid and that the fills are valid at the time of block construction.

§Using SignetEthBundle safely

The SignetEthBundle type contains actions that must be performed on both chains. As such, its simulation must be performed on both chains. The primary transaction simulation via SignetEthBundleDriver is performed locally using trevm. However, the [SignedFill] must be checked against the host chain. This is done by calling the SignetEthBundle::alloy_validate_fills_onchain method. This MUST be called BEFORE simulating.

Builders running in an exex may choose to simulate using the local host chain DB copy. This is not yet implemented in this library, but may be in the future.

Structs§

SignetBundleDriver
A call bundle driver for the Signet EVM.
SignetCallBundle
Bundle of transactions for signet_callBundle.
SignetCallBundleResponse
Response for signet_callBundle.
SignetEthBundle
Bundle of transactions for signet_sendBundle.
SignetEthBundleDriver
Driver for applying a Signet Ethereum bundle to an EVM.
SignetEthBundleResponse
Response for signet_sendBundle.

Enums§

SignetEthBundleError
Errors while running a SignetEthBundle on the EVM.

Type Aliases§

SignetEthBundleInsp
Inspector used in the impl of BundleDriver for SignetEthBundleDriver.