> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nika.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# Troubleshooting & FAQ

> The errors you'll actually hit, what they mean, and the questions everyone asks: version story, runnable state, providers, syntax dialects.

## The questions everyone asks

> [accordion] Can I run Nika today?
>
> Yes. Install the latest tagged release with Homebrew or `install.sh`,
> then run `nika check` and `nika run` locally. 0.124 is the current
> release line. Work stays focused on maintenance, security and the media
> capabilities workflows need; native video is planned for 0.125. A
> grammar change ships with its `nika check --fix` migration.

> [accordion] How are the language and the engine versioned?
>
> Two independent axes. The **language** is versioned by the spec and
> changes only with a migration the binary applies (`nika check --fix`)
> and a refusal that names the move. The **engine** follows semver. 0.124
> is the current release line. Work stays focused on maintenance, security
> and the media capabilities workflows need; native video is planned for
> 0.125. The [roadmap](https://docs.nika.sh/changelog/roadmap.md) keeps the earlier long-range
> plans as history.
> Same model as SQL or GraphQL: the contract is stable, implementations
> iterate.

> [accordion] Is fetch a verb?
>
> No. There are exactly 4 verbs (`infer` · `exec` ·
> `invoke` · `agent`), locked forever. Fetching a URL is *calling a
> tool*: `invoke: { tool: "nika:fetch" }`. If you see `fetch:` as a
> verb anywhere, it's the pre-spec legacy dialect.

> [accordion] Which providers work offline?
>
> 5 local runtimes (Ollama · LM Studio · llama.cpp
> · LocalAI · vLLM), plus the server built into `nika` itself
> ([`nika model serve`](https://docs.nika.sh/guides/local-models)). Point
> `model: ollama/llama3.2:3b` at your machine and the **infer** step stays
> on the machine. "Zero cloud" is about model
> inference: `nika:fetch`, MCP, and other declared tools can still
> call the network if `permits` allow them. `mock/echo` infers with
> nothing at all.

> [accordion] Do I write \{\{ }} or \$\{\{ }}?
>
> Always `${{ … }}`: what's inside is CEL. A bare `{{ … }}` is not a
> reference: it stays literal text, and the run writes the braces.
> `nika check` names it with a `[silent-literal]` hint and the reference it
> meant: `{{ name }}` points to `${{ with.name }}` when the task binds
> `name`, otherwise to `${{ inputs.name }}`. Same rule: there are **no
> template filters** (`| upper`, `| truncate`): transforms are jq, in
> `extract:` bindings or `nika:jq`.

> [accordion] My YAML is valid, so why does nika check still fail?
>
> Schema-valid ≠ spec-valid. The validator also enforces the semantic
> rules: `tasks.*` references live at the boundary only (`with:` ·
> `after:` — a body reference is `NIKA-VAR-021`, hoist it into
> `with:`), `when:` must be a CEL boolean over local namespaces,
> `nika:done` only inside an agent's tool list, exactly one verb per
> task. The error names the exact rule. Fix that rule, nothing else,
> re-check.

## Errors you'll hit, decoded

<video autoPlay muted loop playsInline controls poster="/images/posters/static-check-fix.png" aria-label="nika check stopping a workflow on two mistakes, the fix, and the clean re-check" alt="nika check stopping a workflow on two mistakes, the fix, and the clean re-check">
  <source src="https://mintcdn.com/supernovae-acdf3706/3tG2rJOQxMP3h2LO/videos/static-check-fix.webm?fit=max&auto=format&n=3tG2rJOQxMP3h2LO&q=85&s=14a822fcdadebf3b41b1ed890795d70d" type="video/webm" />

  <source src="https://mintcdn.com/supernovae-acdf3706/3tG2rJOQxMP3h2LO/videos/static-check-fix.mp4?fit=max&auto=format&n=3tG2rJOQxMP3h2LO&q=85&s=6c0c4cdfd3bfd1d6d11ff934fff72b70" type="video/mp4" />
</video>

**Caught before anything runs.** `nika check` stops a pull-request reviewer on two mistakes: a misspelled task name, with the right one suggested, and a value read outside the task's `with:` boundary (`NIKA-VAR-021`, in the table below). Each finding names its fix; after the fix, the same check says the file is ready to run. *Output captured from the real CLI on nika 0.121.0.*

Every failure is a typed structure with a stable code and a `transient`
flag ([error model](https://docs.nika.sh/reference/error-codes.md)). The frequent ones:

| Symptom | Code family | What it means · what to do |
| - | - | - |
| « parse error » on a file that looks fine | `NIKA-PARSE` | Usually the envelope: `nika: <name>` (a kebab-case identifier — `nika: v1` + `workflow:` is the previous envelope, `nika check --fix` migrates it), `tasks:` present. A YAML syntax refusal (`NIKA-PARSE-001`) points a caret at the line and column and names the usual cause: a `:` inside an unquoted value (quote it, or use a block scalar), a `${{ … }}` unquoted inside a `{ … }` mapping (quote the expression), or a bracket the file never closed. A key from another tool's dialect written on the task (`prompt:`, `url:`, `command:`) names the verb that owns it (`NIKA-PARSE-005`). |
| `tasks.X` read refused at check time | `NIKA-VAR-021` · `NIKA-PARSE-024` | A `tasks.*` reference outside the boundary (verb body · `when:` · `for_each:`): hoist it into `with:` — the binding IS the edge (`nika check --fix` applies it). A lingering `depends_on:` is `NIKA-PARSE-024`: data → `with:`, control → `after:`. |
| `jq`/`fromjson` fails on fetch output (« expecting value, byte 0 ») | `NIKA-BUILTIN-JQ` | The fetch used the default `mode: markdown` (built for pages — it escapes JSON bodies). APIs take `mode: raw`, or `mode: jq` + `jq:` so the shaping rides the fetch. |
| « unknown binding » | `NIKA-VAR` · `NIKA-VALUES` | Inside a task body the five value namespaces are `inputs` · `const` · `secrets` · `with` · `tasks` (plus loop locals). That is not every CEL scope: `when:` cannot read `tasks.*` until you hoist, `item`/`index` exist only in `for_each`, outputs may read `tasks` directly. Dead `vars`/`env` is `NIKA-VALUES-001`/`-002`. |
| « no boundary declared » on a workflow that touches something | `NIKA-AUTH-006` | An absent `permits:` block declares ZERO authority, not a free pass. Run `nika check --infer-permits` — it prints the tightest block the body needs, ready to paste. |
| provider call fails once then works | `NIKA-PROVIDER` (`transient: true`) | The engine retries with backoff per your `retry:`. Declare it instead of wrapping logic. |
| fetch refuses a URL | `NIKA-SEC` | SSRF defense: private networks and cloud metadata are blocked by default ([security model](https://docs.nika.sh/concepts/security.md)). |
| command blocked in exec | `NIKA-SEC-001` | Either the always-on exec floor (a destructive or privilege pattern, whatever `permits:` says), or the OS sandbox denied the confined program something: check `permits.fs` for the files it opens. Pass data as argv elements (`exec: { command: [prog, "${{ with.x }}"] }`) or through `stdin:`, never a `shell:` string. Under `nika test` every command is refused by design: the test plane simulates the model, not effects. |
| agent never finishes | `NIKA-AGENT` | Budgets are mandatory leashes: `max_turns` + `max_tokens_total`, and the loop ends with `nika:done`. |

## When it breaks, in order

**1. Read the code, not the message**

`NIKA-<NAMESPACE>-<NNN>`, or a numeric runtime code such as
`NIKA-1709`, is stable and greppable, and `nika explain <code>` teaches
it. The [catalog](https://docs.nika.sh/reference/error-codes.md) gives the namespace's
contract.

**2. Check transient**

`transient: true` → retry can help (declare `retry:` with backoff).
`transient: false` → the input or the file is wrong; retrying burns
money.

**3. Recover structurally**

`on_error: recover:` substitutes a fallback value ·
`on_error: on_codes:` scopes recovery to specific codes (recover the
not-found, still fail loudly on permission-denied).

**4. Ask with context**

Two guided forms exist so nothing gets lost: **[First run
failed](https://github.com/supernovae-st/nika/issues/new?template=first_run_failed.yml)**
(a stumble in your first minutes is a bug, even when nothing
crashed) and **[I was confused
here](https://github.com/supernovae-st/nika/issues/new?template=confused_here.yml)**
(paper cuts are bugs in the teaching). The output of `nika welcome`
is the perfect diagnostic attachment — it prints key *presence*,
never values. For everything else,
[Discussions](https://github.com/supernovae-st/nika/discussions) is
the fastest lane. Security findings: [security@supernovae.studio](mailto:security@supernovae.studio),
never public issues.

> [!NOTE]
>
> Nika ships **zero telemetry** — the binary never phones home. These
> forms and Discussions ARE the project's analytics: a report that you
> reached your first green run in under two minutes is a data point we
> cannot get any other way.

## See also

> [card] [Error codes](https://docs.nika.sh/reference/error-codes.md)
>
> The 25 namespaces + the typed error shape.

> [card] [Templates](https://docs.nika.sh/guides/templates.md)
>
> Skeletons that avoid most of these errors by construction.

> [card] [Security model](https://docs.nika.sh/concepts/security.md)
>
> Why fetch/exec block what they block.

> [card] [Live engine state](https://docs.nika.sh/reference/status.md)
>
> The live engine snapshot, judged by the downloadable binary.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.