stale-build-error
The distinct error thrown when the dist/ the harness is about to install is older than the sources it was built from — the plugin in the vault is not the plugin in the working tree.
The failure it prevents has two directions and the cheap one is not the reason this exists. A suite that FAILS against a stale build costs one confusing run: the symptom is whatever the missing code would have provided, so it reads as a defect in the code under test (observed 2026-09-19: a waitUntil timed out: the enabled event to arrive against a build five hours old, with the plugin loading and registering perfectly — it simply had no component to publish the event). A suite that PASSES against a stale build costs nothing visible and proves nothing: an integration suite exists to be the one test that can fail for the right reason, and a stale artifact silently converts it into a test of last week’s code. Nothing at all reports that direction, which is why the verdict is an error rather than a warning.
Exported so a consumer can instanceof-match this specific setup failure — the same reason ConfigDirectoryFallbackError is.
Classes
Section titled “Classes”| Class | Description |
|---|---|
| StaleBuildError | Thrown by the global setup when the built plugin predates its sources. Carries both timestamps and the newest source’s path, so the message names the file that makes the build stale rather than leaving the reader to find it. |
Interfaces
Section titled “Interfaces”| Interface | Description |
|---|---|
| StaleBuildErrorConstructorParams | Parameters for the StaleBuildError constructor. |