orts 0.2.0

orts core — orbital mechanics simulation, force/torque/sensor models, and WASM plugin host runtime.
Documentation
[package]
name = "orts"
version.workspace = true
edition.workspace = true
license.workspace = true
repository.workspace = true
homepage.workspace = true
rust-version.workspace = true
authors.workspace = true
description = "orts core — orbital mechanics simulation, force/torque/sensor models, and WASM plugin host runtime."
keywords = ["orbital-mechanics", "simulation", "spacecraft", "physics", "aerospace"]
categories = ["science", "simulation"]
# Phase P1: include WIT files so `cargo publish` ships them with
# the crate. Without this, downstream users who enable the
# `plugin-wasm` feature would fail to compile (the `bindgen!` macro
# reads `wit/v0/orts.wit` at build time).
include = [
    "src/**/*",
    "wit/**/*.wit",
    "Cargo.toml",
    "/README.md",
]

[dependencies]
nalgebra.workspace = true
rerun.workspace = true
arika.workspace = true
utsuroi.workspace = true
tobari.workspace = true
log = "0.4.29"
serde_json = { workspace = true }
rand = "0.9.1"
rand_distr = "0.5.0"
serde.workspace = true
thiserror.workspace = true
wasmtime = { workspace = true, optional = true }
wasmtime-wasi = { workspace = true, optional = true }
tokio = { version = "1", default-features = false, features = [
    "rt",
    "rt-multi-thread",
    "sync",
    "time",
], optional = true }

[features]
fetch-weather = ["tobari/fetch"]
fetch-horizons = ["arika/fetch-horizons"]
# Phase P1: load WASM Component guest controllers at runtime via
# wasmtime + Pulley interpreter. See `orts::plugin::wasm`.
plugin-wasm = ["dep:wasmtime", "dep:wasmtime-wasi"]
# Phase P1+: async WASM backend (fiber suspension via wasmtime async).
# Allows a single worker thread to multiplex N satellite controllers
# instead of the default sync backend's thread-per-satellite model.
# Opt-in because it pulls tokio and wasmtime's async feature.
plugin-wasm-async = ["plugin-wasm", "dep:tokio", "wasmtime/async"]

[[example]]
name = "wasm-bdot"
path = "examples/wasm-bdot/main.rs"
required-features = ["plugin-wasm"]

[[example]]
name = "wasm-pd-rw"
path = "examples/wasm-pd-rw/main.rs"
required-features = ["plugin-wasm"]

[dev-dependencies]
proptest = "1.10.0"
serde_json.workspace = true
criterion = { version = "0.8", features = ["html_reports"] }
tokio = { version = "1", features = ["rt", "rt-multi-thread", "macros", "sync", "time"] }

[[bench]]
name = "fiber_overhead"
harness = false
required-features = ["plugin-wasm"]