Skip to content

doctor

ward doctor checks that the project, its tools, and its integrations are ready for Ward.

Terminal window
ward doctor [-C <dir>]
OptionWhat it does
-C, --directory <dir>Inspect the project in <dir> instead of the current directory.
--verbosePrint diagnostics to stderr. See Verbose diagnostics.

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.
CheckStatusMeaning
projectOK / ERRORA supported project was detected. When none is found, only the ward check runs after it.
maven / gradleOK / ERRORFor Java and Kotlin projects: the detected build tool’s wrapper exists in the project root, or its executable (mvn / gradle) is on PATH.
jdkOK / WARNINGFor 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 spotbugsWARNINGFor 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.
nodeOK / ERRORFor TypeScript and JavaScript projects other than Bun: node is on PATH.
node-versionWARNINGFor 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 / bunOK / ERRORFor 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 poetryWARNINGWard does not check that toolchain yet. The finding is named after the build tool, and nothing about Maven is reported.
configurationOK / ERRORward.toml exists in the project root; otherwise run ward init.
integrationOK / WARNINGLists 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.
nativeOK / WARNINGtarget/ward exists in the current directory. This is a development check for the Ward repository.
openspec / openspec-archivedOK / WARNING / ERRORFor 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-traceabilityOK / ERRORWhen enabled, openspec/specs/ and src/test/java/ must exist; doctor does not create them.
dependency-check-nvd-api-keyWARNINGWhen 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.
wardOK / WARNINGCompares 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-indexWARNINGWhen 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 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.

ward --verbose doctor explains the inspection phase and safe availability counts on stderr. Environment contents and filesystem paths are not included in diagnostics.

CodeMeaning
0No check reported ERROR.
2At least one check reported ERROR.