Skip to content

how to contribute debugging

Douwe de Vries edited this page Jul 1, 2026 · 1 revision

Debugging

Use npm run tauri dev when debugging end-to-end behavior. Debug builds enable tauri-plugin-log in src-tauri/src/lib.rs, and k6 output is streamed to the UI through the event layer in src-tauri/src/events.rs.

k6 runtime issues

Symptom Where to look
k6 not found Binary resolution in src-tauri/src/k6/process/runtime.rs
Generated script issue src-tauri/src/importing/script.rs
Missing summary Fallback completion in src-tauri/src/k6/process/runtime.rs
Metrics not updating src-tauri/src/k6/process/live_metrics.rs
Stop state oddity src-tauri/src/k6/process/state.rs and src-tauri/src/commands/testing/mod.rs

Set LOADRIFT_K6_BIN=/path/to/k6 to test a specific k6 executable. Set LOADRIFT_PRESERVE_K6_ARTIFACTS=true only when debugging generated artifacts, because preserved script.js, summary.json, and metrics.json can contain URLs, headers, bodies, and tokens.

Frontend state issues

src/features/test/useTestHarness.ts filters metrics, completion, and error events by run ID. If stale events appear in the UI, check active run tracking in that hook and event emission in src-tauri/src/k6/process/runtime.rs.

Configuration issues

Advanced options must be valid JSON objects. Top-level scenarios, stages, or iterations override the basic load shape in src-tauri/src/k6/process/runtime.rs.

For runtime flags, see Configuration.

Clone this wiki locally