Skip to main content

Crate alloy_chains

Crate alloy_chains 

Source
Expand description

§alloy-chains

Canonical type definitions for EIP-155 chains.

§Supported Rust Versions

Alloy will keep a rolling MSRV (minimum supported rust version) policy of at least 6 months. When increasing the MSRV, the new Rust version must have been released at least six months ago. The current MSRV is 1.85.0.

Note that the MSRV is not increased automatically, and only as part of a minor release.

§Adding a new chain

Add or update the chain in registry/manual.json, then run:

uv run python scripts/update-registry.py

The script updates assets/chains.json and regenerates src/generated/ from the manual registry. Do not edit generated files directly.

§Note on no_std

All crates in this workspace should support no_std environments, with the alloc crate. If you find a crate that does not support no_std, please open an issue.

§License
Licensed under either of Apache License, Version 2.0 or MIT license at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in these crates by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Modules§

spec
Specification of Ethereum EIP-155 chains.

Structs§

Chain
Either a known NamedChain or a EIP-155 chain ID.
NamedChainIter
Iterator over all named chains.
ParseNamedChainError
Error returned when parsing a named chain from a string fails.

Enums§

ChainKind
The kind of chain. Returned by Chain::kind. Prefer using Chain instead.
NamedChain
An Ethereum EIP-155 chain.