Skip to content

Troubleshooting

Start with the full error message and contextcraft --version, keeping credentials and private source out of public reports.

An input cannot be read

Check the selected path and permissions. The CLI accepts one directory or several repository-relative regular files, with symlinks and special files rejected as explicit inputs. Missing or unreadable inputs exit with code 1, while invalid combinations and duplicate paths exit with code 2.

A file is missing from output

Check .gitignore, .ignore, language defaults, and configured exclusions. Hidden paths are included unless disabled, and explicit files bypass discovery exclusions. A discovered file can still receive TREE or be omitted from a tight path listing, so try a larger budget before assuming discovery failed.

Binary, invalid UTF-8, oversized, and sensitive files can remain path-only even with a larger budget. See files and secret protection.

The budget is too small

Increase the positive integer budget or reduce the input set. Framing and paths also consume tokens, and a focus query cannot make an impossible budget fit. Different formats and vocabularies can produce different totals.

A configuration value is rejected

Unknown JSON keys and invalid enum values are errors. CLI and Python settings have different names, such as --budget and budget_tokens, while format, tier, encoding, and secret mode use their documented lowercase values.

Configuration syntax and type errors include a line and column. Refer to configuration for the current schema.

Python cannot load native code

Use a wheel that matches the operating system and architecture. A source build requires Zig 0.17.1, while an installed wheel bundles the library and CLI. Avoid mixing a library from another package version with the Python wrapper.

Use with Engine(...) and with engine.analyze_path(...) to close native handles. Closed handles raise ClosedHandleError, and handles should be created again in a child process after a fork.

The playground looks unstyled

Tailwind loads from its CDN, so check network access. Repository changes require a new CLI session, and --port and --no-open are valid only with --playground.

Report a bug

Include the version, OS, architecture, a minimal input, the command or SDK call, and expected and actual behavior in a bug report. Use synthetic source and follow the security policy for vulnerabilities.