macp-sdk-typescript 0.7.0 → 0.7.1

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.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,13 @@ All notable changes to `macp-sdk-typescript` are documented here. The format
4
4
  follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the
5
5
  project uses [Semantic Versioning](https://semver.org/).
6
6
 
7
+ ## [0.7.1](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/compare/v0.7.0...v0.7.1) (2026-08-31)
8
+
9
+
10
+ ### Bug Fixes
11
+
12
+ * validate explicit empty-string sessionId, and freeze the commitment field set ([#52](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/issues/52)) ([5e4dc25](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/commit/5e4dc25389d948570afbd9653cfd52bc12e97150)), closes [#47](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/issues/47) [#48](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/issues/48)
13
+
7
14
  ## [0.7.0](https://github.com/multiagentcoordinationprotocol/macp-sdk-typescript/compare/v0.6.0...v0.7.0) (2026-08-30)
8
15
 
9
16
 
@@ -26,7 +26,7 @@ class BaseSession {
26
26
  projection;
27
27
  constructor(client, options = {}) {
28
28
  this.client = client;
29
- if (options.sessionId)
29
+ if (options.sessionId !== undefined)
30
30
  (0, validation_1.validateSessionId)(options.sessionId);
31
31
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
32
32
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/decision.js CHANGED
@@ -16,7 +16,7 @@ class DecisionSession {
16
16
  projection = new projections_1.DecisionProjection();
17
17
  constructor(client, options = {}) {
18
18
  this.client = client;
19
- if (options.sessionId)
19
+ if (options.sessionId !== undefined)
20
20
  (0, validation_1.validateSessionId)(options.sessionId);
21
21
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
22
22
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/handoff.js CHANGED
@@ -16,7 +16,7 @@ class HandoffSession {
16
16
  projection = new handoff_1.HandoffProjection();
17
17
  constructor(client, options = {}) {
18
18
  this.client = client;
19
- if (options.sessionId)
19
+ if (options.sessionId !== undefined)
20
20
  (0, validation_1.validateSessionId)(options.sessionId);
21
21
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
22
22
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/proposal.js CHANGED
@@ -16,7 +16,7 @@ class ProposalSession {
16
16
  projection = new proposal_1.ProposalProjection();
17
17
  constructor(client, options = {}) {
18
18
  this.client = client;
19
- if (options.sessionId)
19
+ if (options.sessionId !== undefined)
20
20
  (0, validation_1.validateSessionId)(options.sessionId);
21
21
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
22
22
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/quorum.js CHANGED
@@ -16,7 +16,7 @@ class QuorumSession {
16
16
  projection = new quorum_1.QuorumProjection();
17
17
  constructor(client, options = {}) {
18
18
  this.client = client;
19
- if (options.sessionId)
19
+ if (options.sessionId !== undefined)
20
20
  (0, validation_1.validateSessionId)(options.sessionId);
21
21
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
22
22
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/task.js CHANGED
@@ -16,7 +16,7 @@ class TaskSession {
16
16
  projection = new task_1.TaskProjection();
17
17
  constructor(client, options = {}) {
18
18
  this.client = client;
19
- if (options.sessionId)
19
+ if (options.sessionId !== undefined)
20
20
  (0, validation_1.validateSessionId)(options.sessionId);
21
21
  this.sessionId = options.sessionId ?? (0, envelope_1.newSessionId)();
22
22
  this.modeVersion = options.modeVersion ?? constants_1.DEFAULT_MODE_VERSION;
package/dist/version.d.ts CHANGED
@@ -4,4 +4,4 @@
4
4
  * Kept in sync with package.json by release-please (see the
5
5
  * `x-release-please-version` annotation).
6
6
  */
7
- export declare const VERSION = "0.7.0";
7
+ export declare const VERSION = "0.7.1";
package/dist/version.js CHANGED
@@ -7,4 +7,4 @@ exports.VERSION = void 0;
7
7
  * Kept in sync with package.json by release-please (see the
8
8
  * `x-release-please-version` annotation).
9
9
  */
10
- exports.VERSION = '0.7.0'; // x-release-please-version
10
+ exports.VERSION = '0.7.1'; // x-release-please-version
package/dist/watchers.js CHANGED
@@ -96,6 +96,14 @@ function serverStreamToAsyncGenerator(stream) {
96
96
  stream.cancel();
97
97
  throw err;
98
98
  },
99
+ // Required since TypeScript 6 / @types/node 26, which make `AsyncGenerator`
100
+ // extend `AsyncDisposable` (lib.esnext.disposable). Native `async function*`
101
+ // generators get this for free; this hand-rolled one has to declare it. It
102
+ // also makes every watcher stream usable with `await using`, which cancels
103
+ // the underlying gRPC stream on scope exit exactly like `return()` does.
104
+ async [Symbol.asyncDispose]() {
105
+ stream.cancel();
106
+ },
99
107
  };
100
108
  }
101
109
  class ModeRegistryWatcher {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "macp-sdk-typescript",
3
- "version": "0.7.0",
3
+ "version": "0.7.1",
4
4
  "description": "TypeScript SDK for the MACP Rust runtime",
5
5
  "license": "Apache-2.0",
6
6
  "type": "commonjs",
@@ -59,14 +59,14 @@
59
59
  "protobufjs": "^8.6.5"
60
60
  },
61
61
  "devDependencies": {
62
- "@types/node": "^22.14.0",
63
- "@typescript-eslint/eslint-plugin": "^8.0.0",
64
- "@typescript-eslint/parser": "^8.0.0",
65
- "@vitest/coverage-v8": "^3.0.0",
66
- "eslint": "^9.0.0",
62
+ "@types/node": "^26.4.0",
63
+ "@typescript-eslint/eslint-plugin": "^8.68.0",
64
+ "@typescript-eslint/parser": "^8.68.0",
65
+ "@vitest/coverage-v8": "^4.1.11",
66
+ "eslint": "^10.9.1",
67
67
  "prettier": "^3.0.0",
68
68
  "tsx": "^4.21.0",
69
- "typescript": "^5.8.3",
70
- "vitest": "^3.0.0"
69
+ "typescript": "^6.0.3",
70
+ "vitest": "^4.1.11"
71
71
  }
72
72
  }