doctor
ward doctor checks that the project, its tools, and its integrations are ready for Ward.
ward doctor [-C <dir>]Options
Section titled “Options”| Option | What it does |
|---|---|
-C, --directory <dir> | Inspect the project in <dir> instead of the current directory. |
--verbose | Print diagnostics to stderr. See Verbose diagnostics. |
Checks
Section titled “Checks”Doctor inspects the selected directory, or its nearest supported parent project, and prints one line per check:
[OK] project /path/to/project[OK] maven Maven Wrapper available.[OK] configuration Configuration is present.[OK] integration Configured integrations: codex=installed [[APPROVED_ARTIFACT_GUARD, FEEDBACK, POST_EDIT, PRE_TOOL]].[OK] native Native executable present.[OK] ward v0.2.0 is the latest release.| Check | Status | Meaning |
|---|---|---|
project | OK / ERROR | A supported project was detected. When none is found, only the ward check runs after it. |
maven / gradle | OK / ERROR | For Java and Kotlin projects: the detected build tool’s wrapper exists in the project root, or its executable (mvn / gradle) is on PATH. |
jdk | OK / WARNING | For Java and Kotlin projects: the JDK that runs the build, read from mvn --version or the Gradle launcher JVM, as init reads it. WARNING means the JDK is below 8 (Ward supports Java 8 to 25 and may not work with it), above 25 (not tested or supported; Ward treats it as JDK 25), or that neither the build tool nor its wrapper reported a Java version. The warning does not change the exit status. |
a gate id, such as spotbugs | WARNING | For each gate ward.toml enables whose version pinned in the build file does not run on that JDK, for example spotbugs-maven-plugin 4.9.7.0 runs on JDK 11 to 25; this project builds on JDK 8. Re-run ward init to choose a compatible version. A JDK above 25 is checked as JDK 25. Not reported when the JDK is unknown, and it does not change the exit status. |
node | OK / ERROR | For TypeScript and JavaScript projects other than Bun: node is on PATH. |
node-version | WARNING | For TypeScript and JavaScript projects other than Bun, when the target Node version (from .nvmrc, .node-version, or engines.node) is below 22: Ward supports Node 22 and 24 and may not work with the declared version. The warning does not change the exit status. |
npm / pnpm / yarn / bun | OK / ERROR | For TypeScript and JavaScript projects: the detected package manager’s executable is on PATH. No maven or gradle line is printed. |
Other build tools, such as cargo or poetry | WARNING | Ward does not check that toolchain yet. The finding is named after the build tool, and nothing about Maven is reported. |
configuration | OK / ERROR | ward.toml exists in the project root; otherwise run ward init. |
integration | OK / WARNING | Lists configured project-local agent integrations as id=status [capabilities]. Integrations without pre-tool support are marked advisory-only. installed means the integration’s files are present and Ward-owned; it does not show that the harness has loaded them. WARNING means none is configured (No supported agent integration configured.) or one is incomplete or outdated; re-run ward integrate <agent> to repair it. For a project in a monorepo, agent integrations are looked up at the repository root, where ward init installs them. |
native | OK / WARNING | target/ward exists in the current directory. This is a development check for the Ward repository. |
openspec / openspec-archived | OK / WARNING / ERROR | For each enabled registration, the configured executable and project-root openspec/ directory are available. WARNING means Git ignores openspec/, so CI checkouts will not contain the specs and the gate fails there. |
openspec-junit-traceability | OK / ERROR | When enabled, openspec/specs/ and src/test/java/ must exist; doctor does not create them. |
dependency-check-nvd-api-key | WARNING | When dependency-check is enabled, NVD_API_KEY should be set; without it scans may be very slow or rate-limited. The value is never displayed. |
ward | OK / WARNING | Compares the running version with the latest GitHub release, looking it up now rather than using the update check cache. WARNING means a newer release exists (the line shows how to install it) or the latest release could not be determined, for example offline. OK also covers development builds and WARD_NO_UPDATE_CHECK, which skip the lookup. |
dependency-check-oss-index | WARNING | When dependency-check is enabled and the build leaves the OSS Index analyzer on (explicitly or by the plugin default), OSS_INDEX_PASSWORD should be set; without it scans fail with 401 Unauthorized. Turn the analyzer off or set the variable. Values are never displayed. |
Warnings do not affect the result.
OpenSpec checks
Section titled “OpenSpec checks”OpenSpec diagnosis is conditional and read-only:
- Doctor inspects only enabled registrations in configured profiles.
- It never runs validation, installs a tool, creates an
openspec/directory, or reads artifact contents. - Relative executable paths are resolved against the target root. Bare names use
PATH, and absolute paths are used as supplied.
Verbose diagnostics
Section titled “Verbose diagnostics”ward --verbose doctor explains the inspection phase and safe availability counts on stderr.
Environment contents and filesystem paths are not included in diagnostics.
Exit codes
Section titled “Exit codes”| Code | Meaning |
|---|---|
0 | No check reported ERROR. |
2 | At least one check reported ERROR. |