@vitest-agent/sdk 5.1.3 → 5.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.d.ts +10 -0
  2. package/package.json +2 -2
  3. package/version.js +1 -1
package/index.d.ts CHANGED
@@ -1538,6 +1538,16 @@ export interface ReporterRenderInput {
1538
1538
  */
1539
1539
  export interface VitestAgentReporter {
1540
1540
  readonly render: (input: ReporterRenderInput, kit: ReporterKit) => ReadonlyArray<RenderedOutput>;
1541
+ /**
1542
+ * Release what the factory acquired, once, when Vitest closes (never per
1543
+ * run: watch mode reruns `render` many times on one reporter). The plugin
1544
+ * calls it before it shuts the {@link ReporterKit.runEvents | run-event
1545
+ * channel} down, so a subscriber can still drain what was published (a
1546
+ * shutdown drops what a subscriber has not pulled) and end its own stream;
1547
+ * a live view waits here for its last frame to commit. Optional; the plugin
1548
+ * awaits it and treats a rejection as a logged warning.
1549
+ */
1550
+ readonly close?: () => Promise<void>;
1541
1551
  }
1542
1552
  /**
1543
1553
  * Factory that the plugin's `reporter` option accepts. The plugin calls
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitest-agent/sdk",
3
- "version": "5.1.3",
3
+ "version": "5.2.0",
4
4
  "private": false,
5
5
  "description": "Platform-free core for the vitest-agent package family: Effect Schema definitions, reporter and dispatcher contracts, errors, formatters, and pure utilities.",
6
6
  "keywords": [
@@ -43,7 +43,7 @@
43
43
  "dependencies": {
44
44
  "acorn": "^8.18.0",
45
45
  "acorn-typescript": "^1.4.13",
46
- "effect": "4.0.0-rc.118"
46
+ "effect": "^4.0.0"
47
47
  },
48
48
  "engines": {
49
49
  "node": ">=24.11.0"
package/version.js CHANGED
@@ -11,7 +11,7 @@
11
11
  * survives into the published artifact.
12
12
  * @public
13
13
  */
14
- const CURRENT_SDK_VERSION = "5.1.3";
14
+ const CURRENT_SDK_VERSION = "5.2.0";
15
15
 
16
16
  //#endregion
17
17
  export { CURRENT_SDK_VERSION };