# FAQ: wrong or missing answers

**Niro's graph is read from the code, and some code does not say plainly what it calls.** This page lists the known cases where an answer is wrong or incomplete, and what to do about each. For how to read the marks in an answer, see [How the graph works](https://help.niroai.dev/cli/how-the-graph-works/).

## General

### "Nothing in the graph is called '<name>'."

Check three things, in this order:

- **The spelling.** `resolve_name` lists close matches.

- **The folder.** The code may be in a folder that is not indexed. The tools answer for the folder your agent started in.

- **The graph's age.** It may be out of date: run `niro build`.

### "N files in this folder are not in the graph because they are larger than 2 MB ... rebuilding does not change that"

The name may be in one of those files. Raise `NIRO_LOCAL_MAX_FILE_BYTES` and rebuild if they matter.

### What do "confidence: partial" and "has_more: true" mean?

- **"Partial":** Niro listed every caller it could place, and found others it could not tie to one target.

- **"has_more: true":** the answer is one page of a longer list.

### What do `[possible]`, `[test]` and "inferred, target unconfirmed" mean?

- **`[possible]`:** a caller that may reach the method, but not certainly.

- **`[test]`:** a caller in test code.

- **"Inferred, target unconfirmed":** an HTTP link whose address Niro could not work out. It is not counted in the risk.

With `purpose=VERIFY`, the `[possible]` and `[test]` marks are left out.

### Answers changed between two builds of the same code.

A few answers can differ between builds of the same code. This is a known problem.

### Answers differ from hosted Niro.

They can. The local engine:

- reads test code;

- fixes some mistakes hosted Niro makes (rather than copying them);

- has a few gaps of its own.

`get_impact_analysis` has known differences, for example in the error flags and entry-point tags.

## Missing callers

### "Not listed: N call(s) with this method's name on a receiver of unknown type"

A receiver is the value a method is called on. When the code does not say its type, Niro cannot tell which method the call reaches, so it does not link it. The answer points at those calls: read them.

### A method shows no callers, but a framework calls it.

Methods a framework calls for you (for example a route handler) have no caller in your code. The answer says "it is called by its framework".

### A callback, or a function declared inside another function, shows no callers.

Such a function is reached through what the outer function returns or passes on. The answer says so. Some inner functions have no node at all yet.

### A caller is missing where the call goes through a value typed `any`, `object` or untyped.

Niro cannot know the target, so it does not link the call.

### A caller is missing where the code imports a name under another name.

Imports under another name (aliases) are not always followed.

### A call inside a lambda (a small unnamed function) or a macro is missing.

Some calls inside lambdas, and inside Rust macro arguments, are not recorded.

### `super.method()`, or a method of a parent interface, is not linked.

Some calls to a parent class or interface miss their target.

### An implementation, or the interface that declares the method, shows "0 callers" when its callers use a child interface.

In Java, if interface `B` extends interface `A`, and `A` declares `m()`, a call written on a `B` value (`b.m()`) is linked to a stand-in named `B.m`, not to `A.m`. So asking about `A.m`, or about a class that implements it, answers "0 callers, complete". Ask the name the callers use instead. Example in Keycloak: `JpaUserProvider.getUserByEmail` answers 0 callers, and `UserProvider.getUserByEmail` answers 17, because callers write `session.users().getUserByEmail(...)` and `getUserByEmail` is declared on `UserLookupProvider`, a parent of `UserProvider`. A known problem in this release.

### A call on a value that was cast to another type is missing.

A cast is code that tells the compiler to treat a value as another type. Calls on cast values are not always linked.

### Calls at the top of a file, or in a static block, are missing.

Some calls outside any method are not recorded.

### A call goes to a "stand-in" instead of my code.

A stand-in is a placeholder for a target Niro could not find in your project. Known cases:

- a value made by a factory function;

- a struct literal in Go;

- a namespace import;

- an import from a sibling package in a workspace;

- a Go call to another package in the same module.

### Known gaps by language

- **Python:** calls through a holder object's attribute; `cls()` in a class method; `X | None` types; module-level objects; parameters typed with a project generic; dotted imports of project modules; lookup tables; builtins linked to project methods; `@property` reads; dataclass members; Optional receivers.

- **TypeScript and JavaScript:** overload calls; bare calls to globals; fields typed only by a constructor assignment; arrow functions inside functions; anonymous default exports; functions taken from a React hook's return value.

- **Kotlin:** locals filled by a constructor; `with {}` and `apply {}`; chained calls recorded twice; bare calls guessed project-wide.

- **Swift:** parent types; collection calls; UserDefaults stores.

- **Go:** struct fields and embedded interfaces; aliases stored as parents; generic type methods; pointer receivers; dot imports.

- **Rust:** `impl Trait for` a standard type; `self.field` calls; trait implementers; `use crate::` and `super::` paths; an impl in another file.

- **PHP:** static calls; `$this` typed-property calls; routes registered by calls.

- **C#:** constructor calls to a base class; `global using`; calls through `var` locals.

- **C and C++:** by-value locals; `struct X *p` making a false class; client calls read as routes.

## Routes and calls between services

### A route is missing from `find_api_endpoints`.

Niro lists routes written as fixed text. A route built while the program runs, from computed values, is not in the graph, and the answer says so. If your framework is not recognised, see [Supported languages](https://help.niroai.dev/cli/supported-overview/).

### "(no handler method)" or "(no handler in this project serves it)"

- **"(no handler method)":** Niro found the route, but not the method that serves it.

- **"(no handler in this project serves it)":** a call goes to a route that no code in this project serves.

### An outbound call says "address not stated", or has no address.

The address comes from a setting Niro does not know, such as an environment variable set only when the program is deployed. Tell Niro with `niro env set` or `niro base-url`. See [Configure a folder](https://help.niroai.dev/cli/configuring-a-folder/).

### A call to another service is not linked to that service's route.

Run `niro route-rule unconnected` to see such calls, and add a rule with `niro route-rule add`. Known gaps:

- calls through a proxy such as nginx;

- calls through a shared send method that receives the address;

- calls between modules in one folder.

### Two services with the same route are shown as one.

This is a known problem.

### The service map shows only calls that start in my folder.

`get_service_topology` shows calls from the folder your agent started in.

### Known false links: cases where Niro links code it should not

Niro's own test catalog checks that look-alike code is NOT linked. These cases fail, or are not tested yet:

- **Java: a home-made `@GetMapping`.** An annotation named `@GetMapping` from your own package, with no Spring import, is taken for a Spring route. (Test fails today.)

- **Java: one route on two services.** When two services declare the same path, a call meant for one can be linked to the other. (Test fails today.)

- **Kotlin: the same, with Retrofit.** A Retrofit call to one service is linked to another service that declares the same path. (Test fails today.)

- **C#: a hand-written class shaped like a gRPC base.** A class such as `BillingBase`, written by hand with no gRPC import, should give no route. Not tested yet.

- **C#: generated gRPC code checked into the repository.** Checked-in generated client and service code should add no route and no call of yours. Not tested yet.

Check such links by reading the code they point at.

### Something that is not HTTP is listed as an HTTP call or route.

Some look-alike names are taken for HTTP clients or routes. Examples: a `@mock.patch` test read as a PATCH route, or a map's `put` read as an HTTP PUT. Check them by reading the code.

## Data and events

### A table or data store is missing.

Some libraries record no store. Known cases: drizzle queries, Swift UserDefaults, and file reads with fixed paths in Python.

### A method that changes a loaded JPA entity is listed as a reader, not a writer.

JPA saves a change to an object it loaded (`em.find`, then setters) when the transaction ends, with no further call. Niro sees the `em.find` and lists the method under "read by", or not at all when the object was loaded elsewhere. Example in Keycloak: `get_data_resource_usage resource_fqn=CREDENTIAL` lists `JpaUserCredentialStore.updateCredential` only as a reader, and leaves out `moveCredentialTo`, which reorders priorities. Search the setters with `code_grep` (`answer=names`). A known problem in this release.

### A JPA named query is not listed as a read of its table.

`em.createNamedQuery("name", Entity.class)` is not linked to the entity's table, while `em.persist`, `em.find`, `em.remove`, `createQuery` and `createNativeQuery` are. Example in Keycloak: `get_data_resource_usage resource_fqn=CREDENTIAL` does not list `JpaUserCredentialStore.getStoredCredentialEntities`, which reads it through the named query `credentialByUser`. A known problem in this release.

### A Kafka Streams topology or an Apache Camel route is not listed as a consumer.

`builder.stream("topic")` and `from("kafka:topic?...")` are not read yet, so `get_event_producers_and_handlers` lists fewer handlers than the topic has. Search the topic name with `code_grep` as well.

### Any `.send("text")` is listed as a Kafka event.

A known false match.

### What does `find_orphaned_events` mean by "one side missing"?

An event that is sent but never handled, or handled but never sent. That can mean three things:

- the other side is outside this project;

- the names do not match;

- it is a real gap.

### `get_impact_analysis` ignores `data_resource_fqn`, or `include_http_candidates=false`.

These two inputs are listed but not supported yet. Use `get_data_resource_usage` for a table.

## Exceptions, classes and source

### With `answer=names`, a deep call chain shows a direct callee at depth 2.

On `get_call_chain ... scope=transitive answer=names`, a method that is called directly and also by another direct callee can be labelled with the deeper depth. The count is right. Ask without `answer` when the depth matters.

### Exception flow lists an exception that is caught and wrapped.

Known. A catch is matched only by the exact exception name.

### "Error: direction=upstream needs 'exception_type'"

To ask which callers must handle an exception, name it with `exception_type`.

### "Error: Unrecognised direction"

Use `both`, `upstream` or `downstream` (for chains: `callers` or `callees`).

### Class structure gives a member count but no names, or says "no members".

Known for module files, Python dataclasses and Java enum constructors.

### Parameter lists look wrong outside Java.

Known.

### `get_source_code` printed the wrong file, or a whole test file.

This can happen when the name points at a stand-in. Ask by file and line instead.

### "WARNING: <path> has changed since the last build"

The lines shown come from the file as it is now. They may not match the graph's line numbers until the next build.

## Search and reading files

### "PARTIAL: the search stopped at its 1.5 s limit ... Call again with continue_from=N"

The search ran out of time. Call again with the `continue_from` value it gives, or narrow the search with `path_pattern`.

### `code_grep` in exact mode refuses my text.

Known: exact mode can refuse text that is not a valid regular expression (a search pattern). Escape the special characters.

### "Refused: '<x>' is outside this worktree" or "leads outside this worktree through a symlink"

The tools read only files inside the folder they answer for.

### `get_source_code` refuses a file.

The answer gives one of these reasons:

- the name marks it as a secret or credential file;

- no service in the folder reads its folder;

- it is a symlink;

- it is not a file the tools read;

- the build skips it;

- `.gitignore` covers it;

- it is an editor scratch file.

## Tools

### Where are `find_reusable_code` and `find_known_issues`?

They need LLM documentation, which this release does not include.

### "<tool> is not answered for this folder: it is indexed locally by niro-local, whose graph holds structure and not source text or documentation"

A tool from hosted Niro was asked, and the local graph has nothing for it.

### "Nothing in this folder's graph serves <path>, so the question was not answered"

No route in this folder matches the path asked about.

### "The first 10 of N names are answered above."

A batch question answers 10 names at most. Ask again for the rest.

### A question about another folder gets "Nothing in the graph".

The tools answer for the folder your agent started in. Run `niro ask` from the other folder.

### How do I report a wrong answer?

Email [help@niro.ai](mailto:help@niro.ai) with the question, the answer and what you expected. The coverage audit also reports many gaps by itself. To check an answer before you report it, see [Check what Niro did](https://help.niroai.dev/cli/evaluate-what-niro-did/).