Troubleshooting
doris can’t find the project
doris walks up from the current directory to the first project.hjson whose schema is dv/project/1. If there is none it exits 2, CANNOT_RUN. Run it inside the repo, or pass -C DIR. A project.hjson with another schema is skipped, so check the schema line.
A config file is rejected
Run doris validate. It reports every error in every file at once.
| Message is about | Likely cause |
|---|---|
| An unknown key | A misspelt key. The message lists the valid keys of that table |
A value that ends in } or ] | Two values on one line. An unquoted HJSON value runs to the end of its line (see Writing HJSON) |
A missing or unknown schema | A configs pattern matches a file that is not a doris config, such as another tool’s HJSON. Narrow the pattern |
| No design file | A flow config file has no design.hjson in its directory or above it |
| No tool for a role | Neither the flow config’s tool table nor the project file’s binds a tool to a role the flow needs (see Tools and roles) |
| A role the flow does not have | A misspelt role in a tool table. The message lists the flow’s roles |
A tool that is not a table, a tools that is a list, or an unknown key in dut, reference or tools.<name> | A config written before tools were bound to roles. See below |
| A pattern that matches nothing | A warning. An unquoted glob such as hw/ip/*/dv starts a /* comment: quote it |
A config from before tools were bound to roles
The schema names did not change when the tool table came in, so an older config is rejected key by key. Rewrite it:
| Older config | Now |
|---|---|
Lint’s tool: NAME, or its tools list of linters | tool.linter: a name, or a list of names |
A simulator, or a list of them, named inside TestRIG’s dut | tool.dut: a name, or a list of names |
A reference model named inside TestRIG’s reference | tool.reference |
A simulator’s build arguments, as one list under tools.<name> | tools.<name>.build.args |
A simulator’s run arguments, as one list under tools.<name> | tools.<name>.run.args |
A design is missing from doris flows
Only files that a configs pattern in the project file matches are loaded. A flow config file that no pattern matches is not seen at all, and is neither validated nor run.
doris run exits 2 (CANNOT_RUN) before any step starts
A precheck failed: something a step needs of the machine is not there. doris run prints a setup error: line for each, with the steps that need it, and doris check FLOW DESIGN lists every precheck of the run, passed and failed.
| The line says | Do |
|---|---|
program `NAME` on PATH: not on PATH | Run doris inside the project’s dev shell: doris never installs tools. Or give the tool’s directory with the setting tools.NAME.path |
program `NAME` on PATH: not on PATH, nor in the tool's directory from settings | tools.NAME.path is set, but the program is not in that directory. doris settings shows the value and the file it came from |
environment variable `UVM_HOME` set: not set | Set it to a UVM library Verilator can compile (see Simulators) |
`DIR` exists: no such file or directory | With --replay: the config’s replay directory is missing |
`systemctl --user show --property=Version` exits with code 0 | resources.enforce is systemd, and there is no user systemd manager, as in many containers. Set it to cgroup, or off, for that machine |
doris's own cgroup delegated: ... is not writable | resources.enforce is cgroup, and doris may not write to its cgroup. Set resources.cgroup to one delegated to its user, or start doris in one (see Enforcing what a step holds) |
... does not have the memory controller | The cgroup’s parent does not hand it the memory controller, or cpu. Enable them in the parent’s cgroup.subtree_control, or use another cgroup |
A run also exits 2, CANNOT_RUN, before any step starts if a step holds more of a resource pool than the pool’s size. The message names the step and the pool.
A job ended in step error or setup error
Neither says anything about the design. The job’s result.json and report give the message for the step. The step’s directory is kept whole, with every log, until the step runs again, doris clean removes it, or it is 14 days old.
| Message or symptom | Look at |
|---|---|
| A command exited with an unexpected code | stdout.log and stderr.log in the step’s directory |
| A service never listened | <service>.log in the step’s directory. For Xcelium, a licence queue can outlast the 30 minute limit |
| A service died or had to be killed | <service>.log. The command’s own result is not trusted once a service is lost |
| A timeout | The timeout key of the flow’s config |
| A missing output | The tool exited 0 without doing its work. Read its log |
without ... in its stdout, so it did not finish normally | A pass pattern did not match: the tool ended with an accepted exit code before it printed the line that shows it finished. Read the file the message names |
interrupted | The run was stopped with Ctrl-C (see Interrupting a run) |
doris plan -v FLOW DESIGN prints each step’s exact command and working directory, so a failing command can be run by hand.
A step did not rerun after a change
The cache key covers only what doris knows about (see What is not in a key). A step is not rerun for:
- a change to how doris makes a key or reaches a verdict that did not bump its key protocol, which is a bug in doris (a changed plugin is a miss: its hash is keyed);
- a file a tool reads that is not a declared input, such as a tool install or library;
- a changed environment variable;
- an untracked file that git ignores.
Run with --rerun to run every selected step and replace its cache entry.
A step reran when nothing changed
- The
fileliststep is keyed on every file under the project’scores_rootdirectories. Any change there reruns it, though the steps after it only rerun if the resolved sources changed. Keepcores_rootnarrow. - A TestRIG run in generate mode picks a new seed each time unless one is given, so its run step always runs. Pass
--seed Nor settests.seedto repeat a run. - An untracked, unignored file in an input directory is part of the key. Build products left in a source tree change it: add them to
.gitignore. - A run with
--debugruns each step whose cache entry a run without it stored, because that entry has no debug outputs. Later debug runs take the step from the cache.
A step’s logs are not there
A step that passed keeps only its declared outputs. Its stdout.log, stderr.log and other files are deleted when it ends, unless the step declares them as outputs (see Working directories). The step pages say which files each step keeps.
To read them, run with --debug, which keeps every step’s directory whole:
doris run FLOW DESIGN --debug # runs again each step whose cache entry a plain run stored
doris run FLOW DESIGN --debug --rerun # runs every step
A step that failed or did not complete keeps its directory without --debug, unless the settings have dirs.keep_failed = false.
The logs don’t match this run
A step taken from the cache did not run. Its logs are those of the earlier run that made the entry. Check cached for each step in result.json, or use --rerun.
A job failed but has a coverage report
That is meant. TestRIG’s coverage step runs after a run step that failed, because a run with a failing test still collected coverage. The job is still failed. The step is skipped when run ended in a step error or a setup error.
The cache is too big
doris gc roots lists what is holding it, and doris gc --dry-run shows what a collection would free. See Cleaning the cache.
The scratch directory is too big
The step directories under scratch/doris/ are not part of the cache. A step that passed leaves only its outputs there. What takes the space is the directories kept whole: those of steps that failed or did not complete, and of every step of a run with --debug.
doris clean --dry-run # list them, with the kind and size of each
doris clean # remove them
doris clean --debug # only those a debug run kept
doris run also removes those kept more than 14 days ago, or dirs.work_max_age. The outputs of steps that passed stay until they are deleted by hand: the cache puts them back when they are needed.
A run says it is waiting for another doris run
Another doris run in this checkout is running a job this run wants. This run waits until that one ends, then goes on, taking from the cache what the other ran. Nothing has run or been written yet, so Ctrl-C is safe. To see what holds the job, look for the other doris run process, such as with pgrep -af 'doris run'. To run both at once, run one in another checkout, or give the two runs different designs. See Runs at the same time.
doris gc hangs
It waits for running doris run processes, which hold a lock on the cache from start to end. doris gc --dry-run and doris gc roots don’t wait.
The report of an old run is gone
A past run’s report is made from its GC root, so it goes when the root is collected. Pin runs that must stay: doris gc pin RUN --name NAME.
Reporting a bug
Include the command, the output of doris --version, the job’s result.json, and the output of doris plan -v for the same arguments.