@arcforge/err 2.0.106 → 2.0.107

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 (2) hide show
  1. package/package.json +2 -2
  2. package/src/map.ts +75 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcforge/err",
3
- "version": "2.0.106",
3
+ "version": "2.0.107",
4
4
  "description": "Structured Axon errors — the code map every user-facing failure is rendered from.",
5
5
  "type": "module",
6
6
  "private": false,
@@ -15,7 +15,7 @@
15
15
  "deploy": "echo \"This package is published ONLY by apps/tui/scripts/release.ts, which pins workspace:* deps to concrete versions first. Publishing it directly ships an unresolvable dependency.\" && exit 1"
16
16
  },
17
17
  "dependencies": {
18
- "@arcforge/types": "2.0.106"
18
+ "@arcforge/types": "2.0.107"
19
19
  },
20
20
  "devDependencies": {
21
21
  "@types/bun": "latest",
package/src/map.ts CHANGED
@@ -618,6 +618,41 @@ export const errorMap = {
618
618
  source: "manifest",
619
619
  severity: "fatal",
620
620
  },
621
+ ROUTE_LOAD_FAILED: {
622
+ code: "AX-BLUEPRINT-007",
623
+ title: "Route Load Failed",
624
+ description: "A file in server/api/ could not be imported. The agent would serve an endpoint set that is not the declared one — a caller gets a 404 for a route whose file exists.",
625
+ source: "manifest",
626
+ severity: "fatal",
627
+ },
628
+ SCRIPT_LOAD_FAILED: {
629
+ code: "AX-BLUEPRINT-008",
630
+ title: "Script Load Failed",
631
+ description: "A file in src/scripts/ could not be processed. `axon run <name>` would report the script as not found while its file sits in the project.",
632
+ source: "manifest",
633
+ severity: "fatal",
634
+ },
635
+ PLUGIN_LOAD_FAILED: {
636
+ code: "AX-BLUEPRINT-009",
637
+ title: "Plugin Load Failed",
638
+ description: "A plugin could not be imported. Plugins wire server behaviour at boot; one silently missing means the agent runs without behaviour its author declared.",
639
+ source: "manifest",
640
+ severity: "fatal",
641
+ },
642
+ MIDDLEWARE_LOAD_FAILED: {
643
+ code: "AX-BLUEPRINT-010",
644
+ title: "Middleware Load Failed",
645
+ description: "A middleware file could not be imported. Middleware commonly carries auth and validation, so a silently skipped one is a request path running without the checks its author wrote.",
646
+ source: "manifest",
647
+ severity: "fatal",
648
+ },
649
+ PROMPT_INTROSPECT_FAILED: {
650
+ code: "AX-BLUEPRINT-011",
651
+ title: "Prompt Introspection Failed",
652
+ description: "A .vue prompt could not be introspected for its props. The prompt would render without the inputs it declares, or not at all.",
653
+ source: "manifest",
654
+ severity: "fatal",
655
+ },
621
656
  CONFIG_NOT_FOUND: {
622
657
  code: "AX-BLUEPRINT-003",
623
658
  title: "Config Not Found",
@@ -751,6 +786,46 @@ export const errorMap = {
751
786
  severity: "fatal",
752
787
  },
753
788
 
789
+ // ── Control channel ───────────────────────────────────────────────────────
790
+ // The local socket between a running TUI and the Fleet extension. Both
791
+ // ends dispatch by walking a property path against the handle the peer
792
+ // exposed, so a bad path is the channel's characteristic failure.
793
+ CONTROL_PATH_NOT_FOUND: {
794
+ code: "AX-CONTROL-001",
795
+ title: "Control Path Not Found",
796
+ description: "A control-channel call named a method the peer does not expose. The two ends disagree about the surface — usually a TUI and an extension built from different versions.",
797
+ source: "server",
798
+ severity: "fatal",
799
+ },
800
+ CONTROL_PATH_NOT_CALLABLE: {
801
+ code: "AX-CONTROL-002",
802
+ title: "Control Path Not Callable",
803
+ description: "A control-channel call resolved to a value on the peer's handle that is not a function.",
804
+ source: "server",
805
+ severity: "fatal",
806
+ },
807
+ CONTROL_CALL_FAILED: {
808
+ code: "AX-CONTROL-003",
809
+ title: "Control Call Failed",
810
+ description: "The peer served a control-channel call and it threw. The remote message is carried here — the failure surfaces at the local call site rather than being returned as a falsy value.",
811
+ source: "server",
812
+ severity: "fatal",
813
+ },
814
+ CONTROL_CLOSED: {
815
+ code: "AX-CONTROL-004",
816
+ title: "Control Channel Closed",
817
+ description: "A control-channel call was made, or was still in flight, when the channel closed. In-flight calls reject on close rather than hanging forever on an answer that is no longer coming.",
818
+ source: "server",
819
+ severity: "fatal",
820
+ },
821
+ CONTROL_UNAUTHORIZED: {
822
+ code: "AX-CONTROL-005",
823
+ title: "Control Handshake Rejected",
824
+ description: "A connection to the control socket presented a missing or incorrect token. The token lives in the instance record, which is readable only by the owning user — a mismatch means the caller is not the local Fleet extension.",
825
+ source: "server",
826
+ severity: "fatal",
827
+ },
828
+
754
829
  // ── Server ────────────────────────────────────────────────────────────────
755
830
  PLUGIN_BOOT_FAILED: {
756
831
  code: "AX-SERVER-001",