Tooling

This page lists the tools used to develop fiction. For build requirements and presets, see Getting started. For contribution and review commands, see Contributing.

C++

Tool

Purpose

Configuration and use

CMake and Ninja

Configure and build the library’s tests, experiments, and Python bindings.

CMakeLists.txt and CMakePresets.json; see CMake Presets.

Catch2 and CTest

Write and run C++ tests and micro-benchmarks.

test/; see Building the tests.

clang-format

Format C++ code.

.clang-format; runs through prek.

clang-tidy

Analyze C++ code.

.clang-tidy; uvx nox -s cpp_lint -- --all runs the CI configuration.

ccache

Cache compilations.

FICTION_ENABLE_CACHE; see CMake Presets for the PCH setting.

Python bindings and packaging

Tool

Purpose

Configuration and use

nanobind

Expose C++ APIs to Python and generate type stubs.

bindings/ and python/mnt/pyfiction/; see Bindings Architecture. uvx nox -s stubs regenerates stubs.

scikit-build-core

Build Python packages with CMake.

pyproject.toml.

cibuildwheel

Build and test platform wheels.

pyproject.toml and .github/workflows/cd.yml.

uv

Manage Python dependencies and isolated environments.

pyproject.toml and uv.lock.

nox

Run tests, lint, documentation, and stub-generation sessions.

noxfile.py; uvx nox -l lists sessions.

pytest

Run Python tests.

test/python/ and pyproject.toml; uvx nox -s tests tests supported Python versions, and uvx nox -s minimums checks dependency floors.

Ruff and ty

Format, lint, and type-check Python code.

pyproject.toml; run through prek.

Documentation

Tool

Purpose

Configuration and use

Sphinx, MyST, and Furo

Build and style the documentation from Markdown.

docs/conf.py; see Building the Documentation for previews, HTML builds, and link checks.

Doxygen and Breathe

Render C++ API comments in Sphinx.

docs/Doxyfile; the docs session generates XML for Breathe.

sphinxcontrib-bibtex and bibtex-tidy

Render and format publication references.

docs/references.bib; see Citing Publications.

rumdl

Format and lint MyST Markdown.

.rumdl.toml and .pre-commit-config.yaml; run through prek.

CI and quality checks

Tool

Purpose

Configuration and use

prek

Run formatting and validation hooks.

.pre-commit-config.yaml; prek install installs the commit hook, and prek run -a checks all files.

license-tools

Maintain copyright headers.

.license-tools-config.json; run through prek instead of editing headers by hand.

GitHub Actions

Run builds, tests, packaging, and static analysis.

.github/workflows/; see Contributing for check names and review rules.

Codecov

Report C++ and Python test coverage.

.codecov.yml.

CodeRabbit

Provide automated pull request reviews.

.coderabbit.yaml; see Code Review.

pre-commit.ci

Run hooks and submit formatting fixes.

The ci section in .pre-commit-config.yaml skips ty; GitHub Actions runs the type check.

Renovate

Open dependency-update pull requests.

.github/renovate.json5.