CLVM-rs is a Rust-based implementation of the Chialisp Virtual Machine (CLVM) for the Chia Network's cryptocurrency, designed for enhanced security and performance. It provides Python bindings allowing developers to interact with the CLVM's core functionalities. Currently at version 0.17.5, the library maintains an active development pace with frequent updates and improvements.
pip install clvm-rsVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to assemble a simple Chialisp program, create a `Program` object, and execute it using `run_program`. It shows basic program evaluation and result retrieval. Note that `assemble` is usually part of `clvm_tools_rs` or `clvm_tools`, but often used in conjunction with `clvm_rs`.
Upgrade your Python environment to 3.10 or higher (e.g., `pyenv install 3.10.13`, `conda install python=3.10`).
Update calls from `intern(...)` to `intern_tree(...)` and consider `intern_tree_with_flags` if propagating allocator flags.
Ensure that generated CLVM programs and serialized objects strictly adhere to canonical forms and mempool validation rules. Review and update code that might produce borderline valid CLVM.
Ensure your virtual environment is active and run: `pip install clvm-rs` or `pip install clvm_tools_rs` if you intend to use the higher-level tools.
First, ensure Rust and Cargo are installed (e.g., `curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh`). Then try `pip install clvm-rs` again. For specific architectures like M1 Macs, building from source might be required after cloning the repository and using `maturin develop`.
Install Rust and Cargo using `rustup`: `curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh`. Verify that `~/.cargo/bin` is added to your system's PATH environment variable after installation.
Review the official `clvm-rs` or `clvm_tools_rs` documentation and changelogs for your installed version to identify the correct function name or import path. Ensure all related Chia-Network libraries are updated to compatible versions.