Map the Go repository
Codna builds a dependency and blast-radius graph of the repository from its import patterns. No model call, zero tokens.
Codna maps your Go module for zero tokens, fixes from evidence, and runs go test until it passes.
The problem
Codna builds a dependency and blast-radius graph of the repository from its import patterns. No model call, zero tokens. Package imports are the edges, so the agent follows the call chain from the failing test to the code that should have initialised the value.
How Codna fixes it
Codna builds a dependency and blast-radius graph of the repository from its import patterns. No model call, zero tokens.
The agent receives an evidence bundle scoped to the issue: the suspect files, the call paths, the failing test. Codna prints the raw-to-bundle token size on every run. Every fix reports root cause, confidence, blast radius and regression risk, and passes a risk gate before it is applied or a pull request opens.
Run codna fix --tests --apply and Codna runs your tests in a sandbox and re-fixes until they pass, up to the iteration limit you set. Set fix.test_command in codna.yaml, or pass --test-cmd, when your runner is not pytest. With --open-pr, or through the GitHub App, the pull request states the issue, the root cause, the symbols touched and a confidence score, and asks for review before merging. Codna never merges.
pip install codna codna fix . --issue "TestParseConfig: nil map panic on empty input" --tests --apply --test-cmd "gotestsum --junitfile $CODNA_JUNIT ./..."
What you get
Pass --test-cmd with a command that writes JUnit to $CODNA_JUNIT, or set fix.test_command in codna.yaml.
On-device recall parses .go files with tree-sitter.
Imports are the edges; the evidence bundle carries the call paths into the suspect functions.
The proof
Codna builds a dependency and blast-radius graph of the repository from its import patterns. No model call, zero tokens. The agent receives an evidence bundle scoped to the issue: the suspect files, the call paths, the failing test. Codna prints the raw-to-bundle token size on every run. Every fix reports root cause, confidence, blast radius and regression risk, and passes a risk gate before it is applied or a pull request opens.
Yes, through your test command. Set fix.test_command or pass --test-cmd with a JUnit-writing command; Codna re-runs it until it passes.
The map follows imports and the bundle carries call paths. Dynamic dispatch is a lower bound; your tests verify the behaviour.
The map is built for the whole module, and codna impact narrows a diff to the tests it can affect.
Anything that writes a JUnit report: gotestsum, or go test with a JUnit converter.
Understanding runs on your machine and spends no tokens. Only the evidence bundle or the diff reaches your model provider, with your key from the OS keychain. Set privacy.egress to fail-closed in codna.yaml and Codna runs your tests only under kernel-level network denial. Secret redaction is always on.
Related