NAUTILUS / RUST source 3eb18933
Pages

Rust edition: this guide starts from Cargo crates and native Rust examples. It does not require a foreign-language runtime.

Getting Started

NautilusTrader is a Rust 2024 workspace whose crates are independently consumable. The frozen source used by this edition declares workspace version 0.61.0 and MSRV 1.97.0 in Cargo.toml. Use one source and one revision for every Nautilus dependency so that model types remain nominally identical across the process.

Choose the runtime slice

A live Databento and Interactive Brokers node begins with these crates:

[dependencies]
nautilus-core = "0.61"
nautilus-model = "0.61"
nautilus-live = { version = "0.61", features = ["node"] }
nautilus-trading = "0.61"
nautilus-databento = { version = "0.61", features = ["live", "high-precision"] }

nautilus-interactive-brokers is not published to crates.io at the frozen revision. When it is required, pin the selected Nautilus crates to the same Git revision instead of mixing registry and Git copies:

[dependencies]
nautilus-live = { git = "https://github.com/nautechsystems/nautilus_trader", rev = "<one-reviewed-revision>", features = ["node"] }
nautilus-model = { git = "https://github.com/nautechsystems/nautilus_trader", rev = "<one-reviewed-revision>" }
nautilus-databento = { git = "https://github.com/nautechsystems/nautilus_trader", rev = "<one-reviewed-revision>", features = ["live", "high-precision"] }
nautilus-interactive-brokers = { git = "https://github.com/nautechsystems/nautilus_trader", rev = "<one-reviewed-revision>", features = ["execution", "examples"] }

Sources: Cargo.toml, crates/adapters/databento/Cargo.toml, crates/adapters/interactive_brokers/Cargo.toml.

Decide precision before compiling

The high-precision feature changes the raw width and scale used by core financial values. Standard precision uses 64-bit raw values with nine decimal places; high precision uses 128-bit raw values with sixteen decimal places. All crates that exchange Price, Quantity, Money, Arrow records, or persisted data must agree on this feature.

Databento enables high-precision by default. Disable adapter defaults only when the complete workspace feature policy is explicit.

Run source examples

The selected adapters include native Rust examples:

cargo run --example databento-data-tester --package nautilus-databento
cargo run --example ib-data-tester --package nautilus-interactive-brokers --features examples
cargo run --example ib-exec-tester --package nautilus-interactive-brokers --features examples

The Databento example constructs a LiveNode and data client. The IB examples exercise market-data and execution composition. They are integration probes and may require provider credentials, a running IB Gateway or TWS session, and deliberate paper-trading configuration.

Sources: crates/adapters/databento/examples/node_data_tester.rs, crates/adapters/interactive_brokers/examples/node_data_tester.rs, crates/adapters/interactive_brokers/examples/node_exec_tester.rs.

Verify the crate graph

Before connecting external services, run:

cargo check --workspace
cargo test --workspace
cargo tree -p nautilus-databento
cargo tree -p nautilus-interactive-brokers

Inspect the resolved features and ensure every direct Nautilus package comes from the same version or Git revision. A successful compile proves type compatibility; it does not prove credentials, provider entitlements, reconciliation, or live-order safety.

Continue by subsystem