Skip to content

Latest commit

 

History

History
123 lines (83 loc) · 3.01 KB

DEVELOPMENT.md

File metadata and controls

123 lines (83 loc) · 3.01 KB

Development guide

Development environment

Install Pixi, then enter the repository environment:

pixi shell

Pixi is the canonical development environment and provides the required Rust, Node.js, and pnpm versions. Use another approach at your own risk.

Repository checks

Run the Rust checks from the repository root:

pixi run cargo fmt --all -- --check
pixi run cargo clippy --all-targets --all-features --locked -- -D warnings
pixi run cargo test --all-features --locked --all-targets

These commands check the workspace's default members on every supported platform. Full --workspace checks also include opt-in NVTX and language-bridge crates and are intended for Linux.

Check hand-written C++ and Python sources, including benchmarks and examples:

pixi run format-cpp-check
pixi run format-python-check

Apply formatting with pixi run format-cpp and pixi run format-python. These use the pinned clang-format (LLVM style) and Ruff versions from Pixi.

Check Markdown with the version used by CI:

pixi run --frozen uvx rumdl==0.1.67 check --diff

Run the UI checks from ui/:

pnpm install
pnpm ci:check

Run the query-engine development stack

This workflow additionally requires Docker with the Compose plugin; Pixi does not install Docker.

Docker Compose provides a simulator server and sample event data:

docker compose up --build

The collector listens on port 7836, and the analysis API listens on port 8080. The agent-facing streamable-HTTP MCP endpoint is available on the same server at http://localhost:8080/mcp. This development image intentionally omits the embedded UI so the frontend can run separately with Vite and hot reload.

Run the UI development server

Start Vite separately:

cd ui
pnpm install
pnpm dev

The UI is available at http://localhost:5173. pnpm dev generates the TypeScript bindings before starting Vite. Run pnpm bindings after changing Rust types while the development server remains open.

Run without Docker

Run these commands from separate shells after entering pixi shell. If you are not using an activated Pixi shell, prefix each cargo command with pixi run.

Start the simulator server with CORS enabled for Vite:

cargo run -p quent-simulator-server -- --cors-address http://localhost:5173

Generate a test dataset from another shell:

cargo run -p quent-simulator -- --exporter collector

The analyzer also serves the streamable-HTTP MCP endpoint at http://localhost:8080/mcp.

Build with the bundled UI

The ui feature builds and embeds the static webpage in the server:

cargo build -p quent-simulator-server --features ui --release

Enable Swagger UI

Build the server with the swagger feature:

cargo build -p quent-simulator-server --features ui,swagger --release

Then visit http://localhost:8080/swagger-ui.

Related documentation