SDKs, running, and debugging
Choose a Mojo environment and run or debug a source file.
On this page
Select the environment#
Open the project with its Pixi or uv environment and configure Mojo settings. An explicit SDK wins over automatic discovery. Verify the displayed version and run mojo --version with the same SDK if uncertain.
For new projects, choose the Mojo project wizard and its Pixi or uv workflow. Install dependencies using that project’s environment manager. Keep the manifest and lockfile with source control so team members can reproduce the environment.
Run a file#
Open .mojo source and create or select its Mojo run configuration. Check the source path, working directory, arguments, environment, and SDK. Start with a normal run and inspect compiler diagnostics before attempting debugging.
Package builds use mojo package for the supported b1 toolchain and mojo precompile for b2 and later. New configuration examples use .mojoc; existing serialized package configurations are preserved.
Debug with Pixi#
Use a debugger-capable Pixi SDK containing lldb-dap, the Mojo LLDB plugin, and visualizers. Set a breakpoint on executable source and launch Debug. Inspect stack frames, values, and watches once execution pauses.
If the configuration uses a uv .venv, switch to a supported debugging SDK before retrying. Installing an unrelated IDE debugger plugin does not add missing Mojo toolchain assets.
Manual for version 2026.1.12 · Reviewed