Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
AvalancheGo Compatibility
Crate Version(s) | AvalancheGo Version(s) | Protocol Version |
---|---|---|
v0.0.134-155 | v1.9.2,v1.9.3 | 19 |
v0.0.156-176 | v1.9.4 | 20 |
v0.0.177-200 | v1.9.5 | 21 |
v0.0.201-271 | v1.9.6,v1.9.7 | 22 |
v0.0.272-291 | v1.9.8,v1.9.9 | 23 |
v0.0.292-335 | v1.9.10,v1.9.16 | 24 |
v0.0.336-390 | v1.10.0 | 25 |
v0.0.391+ | v1.10.1+ | 26 |
Introduction
The avalanche-types
crate implements and is the canonical representation of Avalanche primitive types in Rust. Avalanche types are separated by modules and are all under the src
directory.
This crate also provides an SDK library for developing subnets in Rust. For the SDK functionality, see src/subnet
which contains everything required to build a subnet VM in Rust.
The following VMs were built with the SDK:
- Simple Rust VM: TimestampVM
- Complex Rust VM: SpacesVM
Getting Started
Examples can be found in examples
and is a good first step to getting an understanding of general usage.
Tutorials
- How to Build a Simple Rust VM tutorial provides a basic example of using the Rust SDK.
Rust Version
avalanche-types
currently works on Rust 1.67
and above as it requires support for the 2021 edition. This project uses the stable toolchain.
Getting Help
First please try find the answer to your question in the code documentation. If more clarification is required, try opening an issue with the question.
Features
- Ids (e.g.,
src/ids
) - Transaction types/serialization (e.g.,
src/platformvm/txs
) - Certificates (e.g.,
src/key/cert
) - Keys and addresses (e.g.,
src/key/secp256k1
) - Peer-to-peer messages (e.g.,
src/message
) - RPC chain VM (e.g.,
src/subnet/rpc
) - Genesis generate helper (e.g.,
src/subnet_evm
) - Protobuf generated stubs and helpers (e.g.,
src/proto
)
The basic types available in this crate are used in other Avalanche Rust projects (e.g., distributed load tester blizzard
, avalanche-ops
).
License
This project is licensed under the BSD 3.