Thank you for your interest in contributing to Dugite! This document provides guidelines for contributing.
- Fork the repository
- Clone your fork:
git clone git@github.com:YOUR_USERNAME/dugite.git - Create a branch:
git checkout -b feature/your-feature - Make your changes
- Run the checks:
cargo fmt --all && cargo clippy --all-targets -- -D warnings && cargo nextest run --workspace - Commit and push
- Open a pull request
- Rust stable (latest)
- Zero warnings:
RUSTFLAGS="-D warnings"is enforced in CI - Clippy clean:
cargo clippy --all-targets -- -D warningsmust pass - Formatted:
cargo fmt --all -- --checkmust pass - Tests pass:
cargo nextest run --workspacemust pass (orcargo test --allif nextest is not installed)
- Follow standard Rust conventions (rustfmt handles formatting)
- Add comments where logic isn't self-evident
- Include unit tests for new functionality
- Use
thiserrorfor error types in library crates - Use
anyhowfor error handling in binary crates (node, cli) - Prefer
Resultpropagation overunwrap()in non-test code
Dugite is a 14-crate Cargo workspace. See Architecture Overview for details.
Key constraints:
- Dependency DAG: No circular dependencies between crates
- Trait boundaries: Cross-crate interactions via traits, not concrete types
- No unsafe: All unsafe confined to
memmap2I/O (storage crate only) - Cardano wire format: All encoding/decoding via
dugite-serialization(in-house multi-era CBOR decoder)
- Ensure CI passes (build, test, clippy, fmt)
- Update documentation if you changed user-facing behavior
- Add tests for new functionality
- Keep PRs focused — one logical change per PR
- Reference any related issues in the PR description
Use GitHub Issues for bug reports. Include:
- Steps to reproduce
- Expected vs actual behavior
- Dugite version / commit hash
- Network (mainnet/preview/preprod)
- Relevant log output
Do not report security vulnerabilities through public issues. See SECURITY.md for responsible disclosure instructions.
For questions, ideas, and general discussion, use GitHub Discussions.
By contributing, you agree that your contributions will be licensed under the Apache License 2.0.