@smithers-orchestrator/errors 0.16.9 → 0.17.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithers-orchestrator/errors",
3
- "version": "0.16.9",
3
+ "version": "0.17.0",
4
4
  "description": "Error types, tagged errors, and error utilities for Smithers",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -27,6 +27,7 @@
27
27
  "typescript": "~5.9.3"
28
28
  },
29
29
  "scripts": {
30
+ "test": "bun test tests",
30
31
  "typecheck": "tsc -p tsconfig.json --noEmit",
31
32
  "build": "tsup --dts-only"
32
33
  }
@@ -6,5 +6,5 @@ import { smithersErrorDefinitions } from "./smithersErrorDefinitions.js";
6
6
  * @returns {code is KnownSmithersErrorCode}
7
7
  */
8
8
  export function isKnownSmithersErrorCode(code) {
9
- return code in smithersErrorDefinitions;
9
+ return Object.prototype.hasOwnProperty.call(smithersErrorDefinitions, code);
10
10
  }
@@ -48,6 +48,11 @@ export const smithersErrorDefinitions = {
48
48
  when: "A task compute callback exceeds its configured timeout.",
49
49
  details: "{ nodeId, attempt, timeoutMs }",
50
50
  },
51
+ TASK_HIJACK_UNSUPPORTED: {
52
+ category: "engine",
53
+ when: "A task requests auto-hijack but its agent cannot provide a resumable session or conversation.",
54
+ details: "{ nodeId, agentId? }",
55
+ },
51
56
  RUN_NOT_FOUND: {
52
57
  category: "engine",
53
58
  when: "A CLI or engine command references a run ID that does not exist in the database.",
@@ -265,6 +270,10 @@ export const smithersErrorDefinitions = {
265
270
  category: "agents",
266
271
  when: "A CLI-backed agent exits unsuccessfully, streams an explicit error, or its RPC transport fails.",
267
272
  },
273
+ AGENT_CONFIG_INVALID: {
274
+ category: "agents",
275
+ when: "A CLI-backed agent fails with a non-retryable configuration error (e.g. unknown model, missing LLM, unsupported model). Includes agent id, engine and model in details so the offending entry in .smithers/agents.ts can be located.",
276
+ },
268
277
  AGENT_RPC_FILE_ARGS: {
269
278
  category: "agents",
270
279
  when: "Pi RPC mode is used with file arguments that the transport does not support.",