yaml-flow 8.9.2 → 8.11.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.
Files changed (79) hide show
  1. package/browser/asset-integrity.json +5 -5
  2. package/browser/live-cards.js +15 -15
  3. package/browser/live-cards.schema.json +35 -53
  4. package/browser/server-runtime-controlface.js +4 -4
  5. package/examples/board/cards/card-concentration.json +64 -16
  6. package/examples/board/cards/card-my-identity.json +1 -4
  7. package/examples/board/cards/card-portfolio-intelligence.json +1 -5
  8. package/examples/board/cards/card-rebalance-sim.json +1 -4
  9. package/examples/board/cards/cardT-market-prices.json +1 -4
  10. package/examples/board/cards/cardT-portfolio-value.json +35 -10
  11. package/examples/board/cards/cardT-portfolio.json +1 -4
  12. package/lib/board-live-cards-mcp.cjs +1 -1
  13. package/lib/board-live-cards-mcp.d.cts +0 -2
  14. package/lib/board-live-cards-mcp.d.ts +0 -2
  15. package/lib/board-live-cards-mcp.js +1 -1
  16. package/lib/board-live-cards-node.cjs +2 -2
  17. package/lib/board-live-cards-node.js +1 -1
  18. package/lib/board-live-cards-public.cjs +1 -1
  19. package/lib/board-live-cards-public.js +1 -1
  20. package/lib/board-live-cards-server-runtime.cjs +1 -1
  21. package/lib/board-live-cards-server-runtime.js +1 -1
  22. package/lib/board-livegraph-runtime/index.cjs +1 -1
  23. package/lib/board-livegraph-runtime/index.js +1 -1
  24. package/lib/board-state-reducer.cjs +1 -1
  25. package/lib/board-state-reducer.d.cts +1 -0
  26. package/lib/board-state-reducer.d.ts +1 -0
  27. package/lib/board-state-reducer.js +1 -1
  28. package/lib/card-compute/index.cjs +1 -1
  29. package/lib/card-compute/index.js +1 -1
  30. package/lib/card-validation.cjs +1 -1
  31. package/lib/card-validation.js +1 -1
  32. package/lib/chunk-2LGCYN35.js +2 -0
  33. package/lib/chunk-4LHFO56U.js +3 -0
  34. package/lib/{chunk-BVQISI6G.js → chunk-5U5NMYGT.js} +3 -3
  35. package/lib/chunk-6M3RIGUH.js +2 -0
  36. package/lib/chunk-ATOQP3BD.js +2 -0
  37. package/lib/chunk-CPJXGK2T.cjs +2 -0
  38. package/lib/{chunk-OEL5P7XE.js → chunk-CZ6ZFWFT.js} +2 -2
  39. package/lib/{chunk-7W4QQX7S.cjs → chunk-FFHG3CFU.cjs} +2 -2
  40. package/lib/chunk-GHUW6P4G.cjs +2 -0
  41. package/lib/{chunk-ZA4FS27N.js → chunk-H5FKNSCO.js} +3 -3
  42. package/lib/{chunk-GLKWEPX6.js → chunk-MEL5LKF7.js} +2 -2
  43. package/lib/{chunk-KSKPS6OO.cjs → chunk-NMOUBZXX.cjs} +2 -2
  44. package/lib/{chunk-GTHQJXYW.cjs → chunk-O65MSWUE.cjs} +2 -2
  45. package/lib/chunk-QBEQL4TL.cjs +2 -0
  46. package/lib/chunk-QEHKMLHA.cjs +3 -0
  47. package/lib/chunk-U6JMXOER.cjs +3 -0
  48. package/lib/{chunk-YXKWIPQM.cjs → chunk-VNLMJEIX.cjs} +3 -3
  49. package/lib/{chunk-N5RUH4NG.cjs → chunk-X5CZE2L7.cjs} +3 -3
  50. package/lib/chunk-YT76JNKE.js +3 -0
  51. package/lib/{chunk-7E5NKZIO.js → chunk-ZCU5O2LR.js} +2 -2
  52. package/lib/cloud-storage.cjs +1 -1
  53. package/lib/cloud-storage.js +1 -1
  54. package/lib/continuous-event-graph/index.cjs +1 -1
  55. package/lib/continuous-event-graph/index.js +1 -1
  56. package/lib/firestore-storage/index.cjs +1 -1
  57. package/lib/firestore-storage/index.js +1 -1
  58. package/lib/index.cjs +2 -2
  59. package/lib/index.js +1 -1
  60. package/lib/localstorage-storage/index.cjs +1 -1
  61. package/lib/localstorage-storage/index.js +1 -1
  62. package/lib/server-runtime/index.cjs +1 -1
  63. package/lib/server-runtime/index.js +1 -1
  64. package/lib/server-runtime-controlface/index.cjs +1 -1
  65. package/lib/server-runtime-controlface/index.js +1 -1
  66. package/lib/server-runtime-core/index.cjs +1 -1
  67. package/lib/server-runtime-core/index.js +1 -1
  68. package/package.json +1 -1
  69. package/schema/live-cards.schema.json +35 -53
  70. package/lib/chunk-4VZL3GWU.js +0 -3
  71. package/lib/chunk-CBRVINMT.js +0 -2
  72. package/lib/chunk-E46UCDYN.js +0 -2
  73. package/lib/chunk-IRGTOCEU.cjs +0 -2
  74. package/lib/chunk-JHXRGPL7.cjs +0 -3
  75. package/lib/chunk-M53MX233.js +0 -3
  76. package/lib/chunk-NLC4FN7V.cjs +0 -2
  77. package/lib/chunk-RWAEV253.js +0 -2
  78. package/lib/chunk-UG55PF75.cjs +0 -2
  79. package/lib/chunk-WYKCHXBZ.cjs +0 -3
@@ -2,10 +2,15 @@
2
2
  "id": "card-portfolio-intelligence",
3
3
  "meta": {
4
4
  "title": "Portfolio Intelligence",
5
- "tags": ["portfolio", "analysis"],
5
+ "tags": [
6
+ "portfolio",
7
+ "analysis"
8
+ ],
6
9
  "desc": "AI analysis of portfolio mix and P&L. Publishes structured insights as tokens for downstream risk and action cards."
7
10
  },
8
- "requires": ["positions"],
11
+ "requires": [
12
+ "positions"
13
+ ],
9
14
  "source_defs": [
10
15
  {
11
16
  "bindTo": "analysis",
@@ -19,27 +24,70 @@
19
24
  }
20
25
  ],
21
26
  "compute": [
22
- { "bindTo": "mix", "expr": "fetched_sources.analysis.mix" },
23
- { "bindTo": "pnl", "expr": "fetched_sources.analysis.pnl" },
24
- { "bindTo": "risks", "expr": "fetched_sources.analysis.risks" },
25
- { "bindTo": "action", "expr": "fetched_sources.analysis.action" }
27
+ {
28
+ "bindTo": "mix",
29
+ "expr": "fetched_sources.analysis.mix"
30
+ },
31
+ {
32
+ "bindTo": "pnl",
33
+ "expr": "fetched_sources.analysis.pnl"
34
+ },
35
+ {
36
+ "bindTo": "risks",
37
+ "expr": "fetched_sources.analysis.risks"
38
+ },
39
+ {
40
+ "bindTo": "action",
41
+ "expr": "fetched_sources.analysis.action"
42
+ }
26
43
  ],
27
44
  "provides": [
28
- { "bindTo": "portfolio_mix", "ref": "computed_values.mix" },
29
- { "bindTo": "portfolio_pnl", "ref": "computed_values.pnl" },
30
- { "bindTo": "portfolio_risks", "ref": "computed_values.risks" },
31
- { "bindTo": "portfolio_action", "ref": "computed_values.action" }
45
+ {
46
+ "bindTo": "portfolio_mix",
47
+ "ref": "computed_values.mix"
48
+ },
49
+ {
50
+ "bindTo": "portfolio_pnl",
51
+ "ref": "computed_values.pnl"
52
+ },
53
+ {
54
+ "bindTo": "portfolio_risks",
55
+ "ref": "computed_values.risks"
56
+ },
57
+ {
58
+ "bindTo": "portfolio_action",
59
+ "ref": "computed_values.action"
60
+ }
32
61
  ],
33
62
  "view": {
34
63
  "elements": [
35
- { "kind": "markdown", "label": "Mix", "data": { "bind": "computed_values.mix" } },
36
- { "kind": "markdown", "label": "P&L", "data": { "bind": "computed_values.pnl" } }
64
+ {
65
+ "kind": "markdown",
66
+ "label": "Mix",
67
+ "data": {
68
+ "bind": "computed_values.mix"
69
+ }
70
+ },
71
+ {
72
+ "kind": "markdown",
73
+ "label": "P&L",
74
+ "data": {
75
+ "bind": "computed_values.pnl"
76
+ }
77
+ }
37
78
  ],
38
79
  "layout": {
39
- "board": { "col": 3, "order": 4 },
40
- "canvas": { "x": 1300, "y": 50, "w": 340, "h": 200 }
41
- },
42
- "features": { "refresh": true, "chat": true }
80
+ "board": {
81
+ "col": 3,
82
+ "order": 4
83
+ },
84
+ "canvas": {
85
+ "x": 1300,
86
+ "y": 50,
87
+ "w": 340,
88
+ "h": 200
89
+ }
90
+ }
43
91
  },
44
92
  "card_data": {}
45
93
  }
@@ -43,10 +43,7 @@
43
43
  "w": 420,
44
44
  "h": 260
45
45
  }
46
- },
47
- "features": {
48
- "refresh": true
49
46
  }
50
47
  },
51
48
  "card_data": {}
52
- }
49
+ }
@@ -87,11 +87,7 @@
87
87
  "w": 340,
88
88
  "h": 200
89
89
  }
90
- },
91
- "features": {
92
- "refresh": true,
93
- "chat": true
94
90
  }
95
91
  },
96
92
  "card_data": {}
97
- }
93
+ }
@@ -109,10 +109,7 @@
109
109
  "w": 500,
110
110
  "h": 280
111
111
  }
112
- },
113
- "features": {
114
- "refresh": true
115
112
  }
116
113
  },
117
114
  "card_data": {}
118
- }
115
+ }
@@ -73,10 +73,7 @@
73
73
  "w": 400,
74
74
  "h": 340
75
75
  }
76
- },
77
- "features": {
78
- "refresh": true
79
76
  }
80
77
  },
81
78
  "card_data": {}
82
- }
79
+ }
@@ -2,12 +2,21 @@
2
2
  "id": "card-portfolio-value",
3
3
  "meta": {
4
4
  "title": "Portfolio Value",
5
- "tags": ["portfolio", "value"],
5
+ "tags": [
6
+ "portfolio",
7
+ "value"
8
+ ],
6
9
  "desc": "Computes total portfolio value, gainers/losers summary, and per-position P&L from holdings and live market quotes."
7
10
  },
8
- "requires": ["holdings", "quotes"],
11
+ "requires": [
12
+ "holdings",
13
+ "quotes"
14
+ ],
9
15
  "provides": [
10
- { "bindTo": "positions", "ref": "computed_values.positions" }
16
+ {
17
+ "bindTo": "positions",
18
+ "ref": "computed_values.positions"
19
+ }
11
20
  ],
12
21
  "compute": [
13
22
  {
@@ -36,27 +45,43 @@
36
45
  {
37
46
  "kind": "metric",
38
47
  "label": "Portfolio Value ($)",
39
- "data": { "bind": "computed_values.totalValue" }
48
+ "data": {
49
+ "bind": "computed_values.totalValue"
50
+ }
40
51
  },
41
52
  {
42
53
  "kind": "text",
43
- "data": { "bind": "computed_values.gainersLosers" }
54
+ "data": {
55
+ "bind": "computed_values.gainersLosers"
56
+ }
44
57
  },
45
58
  {
46
59
  "kind": "table",
47
60
  "label": "Positions",
48
61
  "data": {
49
62
  "bind": "computed_values.positions",
50
- "columns": ["ticker", "value", "gain_$", "gain_%"],
63
+ "columns": [
64
+ "ticker",
65
+ "value",
66
+ "gain_$",
67
+ "gain_%"
68
+ ],
51
69
  "sortable": true
52
70
  }
53
71
  }
54
72
  ],
55
73
  "layout": {
56
- "board": { "col": 4, "order": 3 },
57
- "canvas": { "x": 840, "y": 50, "w": 420, "h": 380 }
58
- },
59
- "features": { "chat": true }
74
+ "board": {
75
+ "col": 4,
76
+ "order": 3
77
+ },
78
+ "canvas": {
79
+ "x": 840,
80
+ "y": 50,
81
+ "w": 420,
82
+ "h": 380
83
+ }
84
+ }
60
85
  },
61
86
  "card_data": {}
62
87
  }
@@ -51,9 +51,6 @@
51
51
  "w": 320,
52
52
  "h": 340
53
53
  }
54
- },
55
- "features": {
56
- "chat": true
57
54
  }
58
55
  },
59
56
  "card_data": {
@@ -80,4 +77,4 @@
80
77
  }
81
78
  ]
82
79
  }
83
- }
80
+ }
@@ -1,2 +1,2 @@
1
- 'use strict';var chunkIRGTOCEU_cjs=require('./chunk-IRGTOCEU.cjs');require('./chunk-UG55PF75.cjs'),require('./chunk-JHXRGPL7.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"createBoardLiveCardsMcp",{enumerable:true,get:function(){return chunkIRGTOCEU_cjs.a}});//# sourceMappingURL=board-live-cards-mcp.cjs.map
1
+ 'use strict';var chunkGHUW6P4G_cjs=require('./chunk-GHUW6P4G.cjs');require('./chunk-QBEQL4TL.cjs'),require('./chunk-QEHKMLHA.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"createBoardLiveCardsMcp",{enumerable:true,get:function(){return chunkGHUW6P4G_cjs.a}});//# sourceMappingURL=board-live-cards-mcp.cjs.map
2
2
  //# sourceMappingURL=board-live-cards-mcp.cjs.map
@@ -67,8 +67,6 @@ interface BoardLiveCardsMcpRenderedViewElement {
67
67
  resolved?: unknown;
68
68
  }
69
69
  interface BoardLiveCardsMcpRenderedView {
70
- layout: unknown;
71
- features: unknown;
72
70
  elements: BoardLiveCardsMcpRenderedViewElement[];
73
71
  }
74
72
  interface BoardLiveCardsMcpInspectCardDefinitionAndRuntimeResult {
@@ -67,8 +67,6 @@ interface BoardLiveCardsMcpRenderedViewElement {
67
67
  resolved?: unknown;
68
68
  }
69
69
  interface BoardLiveCardsMcpRenderedView {
70
- layout: unknown;
71
- features: unknown;
72
70
  elements: BoardLiveCardsMcpRenderedViewElement[];
73
71
  }
74
72
  interface BoardLiveCardsMcpInspectCardDefinitionAndRuntimeResult {
@@ -1,2 +1,2 @@
1
- export{a as createBoardLiveCardsMcp}from'./chunk-RWAEV253.js';import'./chunk-E46UCDYN.js';import'./chunk-M53MX233.js';import'./chunk-MNEOJWPS.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-mcp.js.map
1
+ export{a as createBoardLiveCardsMcp}from'./chunk-6M3RIGUH.js';import'./chunk-ATOQP3BD.js';import'./chunk-YT76JNKE.js';import'./chunk-MNEOJWPS.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-mcp.js.map
2
2
  //# sourceMappingURL=board-live-cards-mcp.js.map
@@ -1,4 +1,4 @@
1
- 'use strict';var chunkMCPADH33_cjs=require('./chunk-MCPADH33.cjs'),chunkNLC4FN7V_cjs=require('./chunk-NLC4FN7V.cjs'),chunkNBJTYAYN_cjs=require('./chunk-NBJTYAYN.cjs'),chunkGPCMBPLK_cjs=require('./chunk-GPCMBPLK.cjs'),chunkH4TYOSMD_cjs=require('./chunk-H4TYOSMD.cjs'),chunk3CZCGNY4_cjs=require('./chunk-3CZCGNY4.cjs');require('./chunk-6EJRZHFP.cjs'),require('./chunk-N5RUH4NG.cjs');var chunkWRMOGPRG_cjs=require('./chunk-WRMOGPRG.cjs'),chunkYXKWIPQM_cjs=require('./chunk-YXKWIPQM.cjs'),chunk7JVHYHT2_cjs=require('./chunk-7JVHYHT2.cjs'),chunkVQCIOKJV_cjs=require('./chunk-VQCIOKJV.cjs');require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs');var chunkIRGTOCEU_cjs=require('./chunk-IRGTOCEU.cjs'),chunkUG55PF75_cjs=require('./chunk-UG55PF75.cjs'),chunkJHXRGPL7_cjs=require('./chunk-JHXRGPL7.cjs');require('./chunk-UJ7ZTV4J.cjs');var chunk5XLFPPTY_cjs=require('./chunk-5XLFPPTY.cjs'),chunkSDJ3747Q_cjs=require('./chunk-SDJ3747Q.cjs'),chunkP7ZCDICS_cjs=require('./chunk-P7ZCDICS.cjs');require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');var child_process=require('child_process'),i=require('fs'),qe=require('os'),w=require('path'),Le=require('net'),url=require('url'),crypto=require('crypto'),module$1=require('module'),properLockfile=require('proper-lockfile');var _documentCurrentScript=typeof document!=='undefined'?document.currentScript:null;function _interopNamespace(e){if(e&&e.__esModule)return e;var n=Object.create(null);if(e){Object.keys(e).forEach(function(k){if(k!=='default'){var d=Object.getOwnPropertyDescriptor(e,k);Object.defineProperty(n,k,d.get?d:{enumerable:true,get:function(){return e[k]}});}})}n.default=e;return Object.freeze(n)}var i__namespace=/*#__PURE__*/_interopNamespace(i);var qe__namespace=/*#__PURE__*/_interopNamespace(qe);var w__namespace=/*#__PURE__*/_interopNamespace(w);var Le__namespace=/*#__PURE__*/_interopNamespace(Le);function C(...e){return w__namespace.join(...e)}function Ne(e){return w__namespace.isAbsolute(e)}function ue(){return crypto.randomUUID()}function Qe(e){return crypto.createHash("sha256").update(e).digest("hex")}function Je(e){return w__namespace.dirname(url.fileURLToPath(e))}function Ft(e){if(typeof e=="object"&&e!==null){let{command:r,args:o=[],...n}=e,s=Oe(r,o);return {...n,command:s.command,args:s.args}}let t=De(e);if(t.length===0)throw new Error(`Empty command spec: ${JSON.stringify(e)}`);return Oe(t[0],t.slice(1))}function Oe(e,t){return /^(node|node\.exe)$/i.test(e)?{command:process.execPath,args:t}:/\.m?js$/i.test(e)?{command:process.execPath,args:[e,...t]}:{command:e,args:t}}function De(e){let t=[],r="",o=null;for(let n of e.trim()){if(o){n===o?o=null:r+=n;continue}if(n==='"'||n==="'"){o=n;continue}if(/\s/.test(n)){r&&(t.push(r),r="");continue}r+=n;}if(o)throw new Error(`Unterminated quote in command: ${e}`);return r&&t.push(r),t}function Ke(e){return process.platform==="win32"&&/\.(cmd|bat)$/i.test(e)}function We(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u}=e;return child_process.execFileSync(r,o,{shell:Ke(r),timeout:u,encoding:t?.encoding??"utf-8",cwd:n,windowsHide:true,env:s?{...process.env,...s}:void 0,input:t?.input})}function $t(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u=3e4}=e;child_process.execFile(r,o,{shell:Ke(r),encoding:"utf8",windowsHide:true,timeout:u,maxBuffer:10*1024*1024,cwd:n,env:s?{...process.env,...s}:void 0},(p,x,c)=>t(p??null,x,c));}function He(e,t,r){let o=w__namespace.join(e,"board-live-cards-cli.js");if(i__namespace.existsSync(o))return {cmd:process.execPath,args:[o,t,...r]};let n=w__namespace.join(e,"board-live-cards-cli.ts"),u=[w__namespace.join(e,"..","..","..","node_modules","tsx","dist","cli.mjs"),w__namespace.join(e,"..","..","node_modules","tsx","dist","cli.mjs"),w__namespace.join(e,"..","..","..","node_modules",".bin","tsx"),w__namespace.join(e,"..","..","node_modules",".bin","tsx")].find(x=>i__namespace.existsSync(x));return i__namespace.existsSync(n)&&u?{cmd:process.execPath,args:[u,n,t,...r]}:{cmd:process.platform==="win32"?"npx.cmd":"npx",args:["tsx",n,t,...r]}}function Ve(e){let t=w__namespace.join(e,"board-live-cards-cli.mjs");if(i__namespace.existsSync(t))return t;let r=w__namespace.join(e,"..","..","..","dev","board-live-cards-cli.js");if(i__namespace.existsSync(r))return r;let o=w__namespace.join(e,"..","..","dev","board-live-cards-cli.js");if(i__namespace.existsSync(o))return o;let n=w__namespace.join(e,"board-live-cards-cli.js");if(i__namespace.existsSync(n))return n;throw new Error(`resolveBoardCliCallbackTarget: cannot find callback target in ${e} (expected dev/board-live-cards-cli.js wrapper, ${n}, or ${t})`)}function Mt(e){return process.platform==="win32"?`\\\\.\\pipe\\${e}`:w__namespace.join(qe__namespace.tmpdir(),`${e}.sock`)}var ce=new Map;function Ue(e,t,r){if(t.length===0)return;let o=t.map(p=>JSON.stringify(p)).join(`
1
+ 'use strict';var chunkMCPADH33_cjs=require('./chunk-MCPADH33.cjs'),chunkCPJXGK2T_cjs=require('./chunk-CPJXGK2T.cjs'),chunkNBJTYAYN_cjs=require('./chunk-NBJTYAYN.cjs'),chunkGPCMBPLK_cjs=require('./chunk-GPCMBPLK.cjs'),chunkH4TYOSMD_cjs=require('./chunk-H4TYOSMD.cjs'),chunk3CZCGNY4_cjs=require('./chunk-3CZCGNY4.cjs');require('./chunk-6EJRZHFP.cjs'),require('./chunk-X5CZE2L7.cjs');var chunkWRMOGPRG_cjs=require('./chunk-WRMOGPRG.cjs'),chunkVNLMJEIX_cjs=require('./chunk-VNLMJEIX.cjs'),chunk7JVHYHT2_cjs=require('./chunk-7JVHYHT2.cjs'),chunkVQCIOKJV_cjs=require('./chunk-VQCIOKJV.cjs');require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs');var chunkGHUW6P4G_cjs=require('./chunk-GHUW6P4G.cjs'),chunkQBEQL4TL_cjs=require('./chunk-QBEQL4TL.cjs'),chunkQEHKMLHA_cjs=require('./chunk-QEHKMLHA.cjs');require('./chunk-UJ7ZTV4J.cjs');var chunk5XLFPPTY_cjs=require('./chunk-5XLFPPTY.cjs'),chunkSDJ3747Q_cjs=require('./chunk-SDJ3747Q.cjs'),chunkP7ZCDICS_cjs=require('./chunk-P7ZCDICS.cjs');require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');var child_process=require('child_process'),i=require('fs'),qe=require('os'),w=require('path'),Le=require('net'),url=require('url'),crypto=require('crypto'),module$1=require('module'),properLockfile=require('proper-lockfile');var _documentCurrentScript=typeof document!=='undefined'?document.currentScript:null;function _interopNamespace(e){if(e&&e.__esModule)return e;var n=Object.create(null);if(e){Object.keys(e).forEach(function(k){if(k!=='default'){var d=Object.getOwnPropertyDescriptor(e,k);Object.defineProperty(n,k,d.get?d:{enumerable:true,get:function(){return e[k]}});}})}n.default=e;return Object.freeze(n)}var i__namespace=/*#__PURE__*/_interopNamespace(i);var qe__namespace=/*#__PURE__*/_interopNamespace(qe);var w__namespace=/*#__PURE__*/_interopNamespace(w);var Le__namespace=/*#__PURE__*/_interopNamespace(Le);function C(...e){return w__namespace.join(...e)}function Ne(e){return w__namespace.isAbsolute(e)}function ue(){return crypto.randomUUID()}function Qe(e){return crypto.createHash("sha256").update(e).digest("hex")}function Je(e){return w__namespace.dirname(url.fileURLToPath(e))}function Ft(e){if(typeof e=="object"&&e!==null){let{command:r,args:o=[],...n}=e,s=Oe(r,o);return {...n,command:s.command,args:s.args}}let t=De(e);if(t.length===0)throw new Error(`Empty command spec: ${JSON.stringify(e)}`);return Oe(t[0],t.slice(1))}function Oe(e,t){return /^(node|node\.exe)$/i.test(e)?{command:process.execPath,args:t}:/\.m?js$/i.test(e)?{command:process.execPath,args:[e,...t]}:{command:e,args:t}}function De(e){let t=[],r="",o=null;for(let n of e.trim()){if(o){n===o?o=null:r+=n;continue}if(n==='"'||n==="'"){o=n;continue}if(/\s/.test(n)){r&&(t.push(r),r="");continue}r+=n;}if(o)throw new Error(`Unterminated quote in command: ${e}`);return r&&t.push(r),t}function Ke(e){return process.platform==="win32"&&/\.(cmd|bat)$/i.test(e)}function We(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u}=e;return child_process.execFileSync(r,o,{shell:Ke(r),timeout:u,encoding:t?.encoding??"utf-8",cwd:n,windowsHide:true,env:s?{...process.env,...s}:void 0,input:t?.input})}function $t(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u=3e4}=e;child_process.execFile(r,o,{shell:Ke(r),encoding:"utf8",windowsHide:true,timeout:u,maxBuffer:10*1024*1024,cwd:n,env:s?{...process.env,...s}:void 0},(p,x,c)=>t(p??null,x,c));}function He(e,t,r){let o=w__namespace.join(e,"board-live-cards-cli.js");if(i__namespace.existsSync(o))return {cmd:process.execPath,args:[o,t,...r]};let n=w__namespace.join(e,"board-live-cards-cli.ts"),u=[w__namespace.join(e,"..","..","..","node_modules","tsx","dist","cli.mjs"),w__namespace.join(e,"..","..","node_modules","tsx","dist","cli.mjs"),w__namespace.join(e,"..","..","..","node_modules",".bin","tsx"),w__namespace.join(e,"..","..","node_modules",".bin","tsx")].find(x=>i__namespace.existsSync(x));return i__namespace.existsSync(n)&&u?{cmd:process.execPath,args:[u,n,t,...r]}:{cmd:process.platform==="win32"?"npx.cmd":"npx",args:["tsx",n,t,...r]}}function Ve(e){let t=w__namespace.join(e,"board-live-cards-cli.mjs");if(i__namespace.existsSync(t))return t;let r=w__namespace.join(e,"..","..","..","dev","board-live-cards-cli.js");if(i__namespace.existsSync(r))return r;let o=w__namespace.join(e,"..","..","dev","board-live-cards-cli.js");if(i__namespace.existsSync(o))return o;let n=w__namespace.join(e,"board-live-cards-cli.js");if(i__namespace.existsSync(n))return n;throw new Error(`resolveBoardCliCallbackTarget: cannot find callback target in ${e} (expected dev/board-live-cards-cli.js wrapper, ${n}, or ${t})`)}function Mt(e){return process.platform==="win32"?`\\\\.\\pipe\\${e}`:w__namespace.join(qe__namespace.tmpdir(),`${e}.sock`)}var ce=new Map;function Ue(e,t,r){if(t.length===0)return;let o=t.map(p=>JSON.stringify(p)).join(`
2
2
  `)+`
3
3
  `,n=ce.get(e);if(n&&!n.socket.destroyed){n.ready?n.socket.write(o):n.queue.push(o);return}let s=Mt(e),u=Le__namespace.createConnection(s);n={socket:u,ready:false,queue:[o]},ce.set(e,n),u.on("connect",()=>{n.ready=true;for(let p of n.queue)u.write(p);n.queue.length=0;}),u.on("error",p=>{r?.(`[named-pipe publish] ${s}: ${p instanceof Error?p.message:String(p)}`),ce.delete(e);}),u.on("close",()=>{ce.delete(e);});}function ze(){return {executeSync(e,t,r){return We({command:e,args:t,cwd:r?.cwd,timeoutMs:r?.timeout,env:r?.env},{encoding:r?.encoding,input:r?.input})},executeAsync(e,t,r){$t({command:e,args:t},r);},resolveInvocation(e,t){let r=Ft({command:e,args:t});return {cmd:r.command,args:r.args??[]}},splitCommand:De}}function xe(e){return {id:e.id??"board-worker",pollIntervalMs:e.pollIntervalMs,visibilityMs:e.visibilityMs,concurrency:e.concurrency,maxAttempts:e.maxAttempts,async lease(t){return e.workerStore.leaseRequests(t).map(r=>({id:r.messageId,attempt:r.attempt,message:r.request,ack:()=>e.workerStore.ackRequest(r.messageId,r.leaseToken),nack:o=>e.workerStore.nackRequest(r.messageId,r.leaseToken,o)}))},async handle(t){await e.handleRequest(t.args,t);},onError:e.onError}}function we(e){return {id:e.id,pollIntervalMs:e.pollIntervalMs,visibilityMs:e.visibilityMs,concurrency:e.concurrency,maxAttempts:e.maxAttempts,async lease(t){return e.queueStorage.lease(t).map(r=>({id:r.id,attempt:r.attempt,message:r.body,ack:()=>e.queueStorage.ack(r.id,r.leaseToken),nack:o=>e.queueStorage.nack(r.id,r.leaseToken,o)}))},handle:e.handleMessage,onError:e.onError}}async function Ge(e,t){try{await e.handle(t.message,t),await t.ack();}catch(r){let o=t.attempt>=Math.max(1,Math.floor(e.maxAttempts??5));await t.nack({dead:o,reason:r instanceof Error?r.message:String(r)}),e.onError?.(r,t);}}function Ye(e){let t=Math.max(1,Math.floor(e.pollIntervalMs??250)),r=Math.max(1,Math.floor(e.visibilityMs??6e4)),o=Math.max(1,Math.floor(e.concurrency??1)),n=false,s=false;async function u(){if(!(n||s)){s=true;try{let x=await e.lease({max:o,visibilityMs:r});for(let c of x)await Ge(e,c);}finally{s=false;}}}let p=setInterval(()=>{u();},t);return typeof p.unref=="function"&&p.unref(),u(),()=>{n=true,clearInterval(p);}}async function _t(e){let t=Math.max(1,Math.floor(e.visibilityMs??6e4)),r=Math.max(1,Math.floor(e.concurrency??1)),o=await e.lease({max:r,visibilityMs:t});for(let n of o)await Ge(e,n);return o.length}async function de(e,t){let r=Math.max(1,Math.floor(t?.maxPasses??256)),o=0;for(let n=0;n<r;n+=1){let s=await _t(e);if(o+=s,s<=0)return o}throw new Error(`drainQueueLaneToIdle exceeded ${r} passes for lane "${e.id}"`)}function Ot(e){let r=(Array.isArray(e)?e:e.lanes).map(o=>Ye(o));return ()=>{for(let o of r)o();}}var Lt=module$1.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('board-live-cards-node.cjs', document.baseURI).href)));function Nt(e){return typeof e=="object"?e:chunkVQCIOKJV_cjs.b(e)}function Xe(e){let t=w__namespace.basename(String(e||"").trim());if(!t)throw new Error(`resolveYamlFlowCliPath: expected non-empty cli file name, got ${JSON.stringify(e)}`);let r=w__namespace.dirname(Lt.resolve("yaml-flow/package.json")),o=t.replace(/\.[^.]+$/,""),n=w__namespace.join(r,"cli","bundled",`${o}.mjs`);if(i__namespace.existsSync(n))return n;let s=w__namespace.join(r,"cli","node",t);if(i__namespace.existsSync(s))return s;throw new Error(`resolveYamlFlowCliPath: could not find ${t} under cli/bundled or cli/node in ${r}`)}function L(e){let t=Nt(e);return t.kind==="yaml-flow-cli"?Xe(t.value):t.value}function Qt(e,t){let r=L(e);switch(r){case "source-cli-task-executor":{let o=w__namespace.join(t,"source-cli-task-executor.js");if(i__namespace.existsSync(o))return {command:process.execPath,args:[o]};let n=w__namespace.join(t,"source-cli-task-executor.ts"),s=w__namespace.join(t,"..","..","node_modules","tsx","dist","cli.mjs"),u=w__namespace.join(t,"..","..","node_modules",".bin","tsx"),p=i__namespace.existsSync(s)?s:u;return i__namespace.existsSync(n)&&i__namespace.existsSync(p)?{command:process.execPath,args:[p,n]}:{command:process.execPath,args:[o]}}case "board-live-cards":{let{cmd:o,args:n}=He(t,"_",[]);return {command:o,args:n}}default:throw new Error(`resolveBuiltIn: unknown built-in name "${r}". Supported: source-cli-task-executor, board-live-cards`)}}function Jt(e,t){if(e.howToRun==="built-in"){let{command:o,args:n}=Qt(e.whatToRun,t);return {command:o,baseArgs:n}}let r=(typeof e.whatToRun=="object",L(e.whatToRun));switch(e.howToRun){case "local-node":return {command:process.execPath,baseArgs:[r]};case "local-python":return {command:process.platform==="win32"?"python":"python3",baseArgs:[r]};case "local-process":return {command:r,baseArgs:[]};default:throw new Error(`resolveBaseInvocation: howToRun "${e.howToRun}" is not a local transport`)}}function le(e,t){return Jt(e,t)}var be=new Map;function Dt(e,t){let r=String(e||"").trim();if(!r)throw new Error("registerInProcessExecutionHandler: key is required");be.set(r,t);}function Kt(e){let t=String(e||"").trim();t&&be.delete(t);}function et(e){let t=e.trim();if(!t)throw new Error("empty stdout");try{return JSON.parse(t)}catch{let r=t.split(/\r?\n/).filter(Boolean),o=r[r.length-1];return JSON.parse(o)}}function tt(e,t){return {...t,whatToRun:L(e.whatToRun),...e.extra?{extra:e.extra}:{}}}function ke(e,t,r="invokeExecutionRef"){return chunk3CZCGNY4_cjs.a(e,t,r)}function rt(e,t){if(e&&typeof e=="object"&&!Array.isArray(e)&&typeof e.result=="string"&&e.data&&typeof e.data=="object"&&!Array.isArray(e.data))return {...e,...t||{}};if(e&&typeof e=="object"&&!Array.isArray(e)&&typeof e.status=="string"){let o=e,n=o.status==="success"?"success":o.status==="fail"?"failure":o.status,s=o.data&&typeof o.data=="object"&&!Array.isArray(o.data)?o.data:o.data===void 0?{}:{stdout:o.data};return {result:n,data:s,...typeof o.error=="string"?{error:o.error}:{},...t||{}}}return {result:"success",data:e&&typeof e=="object"&&!Array.isArray(e)?e:{stdout:e},...t||{}}}function q(e){return {result:"failure",data:{error:e}}}function V(e,t,r){let o=r?.label??"invokeExecutionRefSync",n=r?.cliDir??r?.cwd??process.cwd(),s;try{s=ke(e.argsMassaging,tt(e,t),o);}catch(h){let R=h instanceof Error?h.message:String(h);return q(R)}let u;try{u=le(e,n);}catch(h){let R=h instanceof Error?h.message:String(h);return q(`[${o}] ref resolution failed: ${R}`)}let p=[...u.baseArgs,...s.cmdArgs??[]],x=JSON.stringify(s.stdin??t),c=ze(),l;try{l=c.executeSync(u.command,p,{timeout:r?.timeoutMs??3e4,encoding:"utf-8",cwd:r?.cwd,input:x});}catch(h){let R=h,y=(R.stderr?String(R.stderr):"").trim(),d=typeof R.status=="number"?R.status:"unknown",f=y||R.message;return q(`[${o}] ref exited with status ${d}${f?`: ${f}`:""}`)}try{return rt(et(l))}catch{return {result:"success",data:{stdout:l.trim()}}}}async function Ze(e,t,r){let o=r?.label??"invokeExecutionRef",n;try{n=ke(e.argsMassaging,tt(e,t),o);}catch(h){let R=h instanceof Error?h.message:String(h);return q(R)}let s=L(e.whatToRun),u=n.headers?{"Content-Type":"application/json",...n.headers}:{"Content-Type":"application/json"},p=n.url??s,x;if(e.howToRun==="http:get"){let h=n.body&&typeof n.body=="object"&&!Array.isArray(n.body)?n.body:t,R=new URLSearchParams(Object.entries(h).filter(([,y])=>y!=null).map(([y,d])=>[y,String(d)]));R.size>0&&(p=`${p}${p.includes("?")?"&":"?"}${R.toString()}`);}else x=JSON.stringify(n.body??t);let c={method:e.howToRun==="http:get"?"GET":"POST",headers:u,body:x},l=0;for(;;)try{let h=await fetch(p,c);if(!h.ok){let f=await h.text().catch(()=>"");return q(`[${o}] HTTP ${h.status}${f?`: ${f}`:""}`)}let R={};h.headers.forEach((f,m)=>{R[m]=f;});let y=new Uint8Array(await h.arrayBuffer());if(y.byteLength===0)return {result:"success",data:{},headers:R};let d=new TextDecoder().decode(y);try{return rt(et(d),{headers:R})}catch{return {result:"success",data:{stdout:d},headers:R}}}catch(h){let R=h?.cause,y=R&&typeof R=="object"&&"code"in R?String(R.code||""):"";if((y==="ECONNRESET"||y==="UND_ERR_SOCKET")&&l===0){l+=1;continue}let f=h instanceof Error?h.message:String(h),m=R instanceof Error?`${R.name}: ${R.message}${y?` [${y}]`:""}`:R?String(R):"",S=n.url??s??"",a=`${f}${m?` (cause: ${m})`:""}${S?` url=${S}`:""}`;return q(`[${o}] ${a}`)}}async function Wt(e,t,r){let o=r?.label??"invokeExecutionRef",n=L(e.whatToRun).trim();if(!n)return q(`[${o}] in-process-loop requires a non-empty handler key`);let s=be.get(n);if(!s)return q(`[${o}] no in-process handler registered for: ${n}`);try{return await s(e,t,r)}catch(u){let p=u instanceof Error?u.message:String(u);return q(`[${o}] ${p}`)}}var Ht={"local-node":async(e,t,r)=>V(e,t,r),"local-python":async(e,t,r)=>V(e,t,r),"local-process":async(e,t,r)=>V(e,t,r),"built-in":async(e,t,r)=>V(e,t,r),"http:post":Ze,"http:get":Ze,"in-process-loop":Wt},Vt={"local-node":V,"local-python":V,"local-process":V,"built-in":V};async function Z(e,t,r){let o=r?.transports?.[e.howToRun]??Ht[e.howToRun];return o?o(e,t,r):q(`[${r?.label??"invokeExecutionRef"}] unsupported howToRun: ${e.howToRun}`)}function ve(e,t,r){let o=r?.syncTransports?.[e.howToRun]??Vt[e.howToRun];return o?o(e,t,r):q(`[${r?.label??"invokeExecutionRefSync"}] unsupported sync howToRun: ${e.howToRun}`)}function Ut(e){return {invoke(t,r){return Z(t,r,e)},invokeSync(t,r){return ve(t,r,e)}}}function zt(e,t,r){return ve(e,t,r)}function Ae(e={}){let t=e.resolveRef??(r=>r);return {...e.executorTimeouts?{executorTimeouts:e.executorTimeouts}:{},async invokeExecutor(r,o,n){let s=t(r);if(s.howToRun==="queue-storage")throw new Error("queue-storage does not support inline executor request/response");if(s.howToRun==="http:post"||s.howToRun==="in-process-loop"){let l=await chunkH4TYOSMD_cjs.h(s,{subcommand:o,...n?.input!==void 0?{input:n.input}:{}});return typeof l=="string"?l:l&&typeof l=="object"&&!Array.isArray(l)&&typeof l.stdout=="string"?String(l.stdout):JSON.stringify(l??{})}if(s.howToRun==="http:get"){let l=await Z(s,{subcommand:o,...n?.input!==void 0?{input:n.input}:{},...s.extra?{extra:s.extra}:{}},{cwd:process.cwd(),timeoutMs:n?.timeout??3e4,label:`invokeExecutor:${o}`});if(l.result!=="success"){let h=typeof l.data?.error=="string"?l.data.error:l.error;throw new Error(h||`executor request failed: ${l.result}`)}return typeof l.data?.stdout=="string"?l.data.stdout:JSON.stringify(l.data??{})}if(!e.resolveCliDir)throw new Error(`createNonCoreExecutorDispatcher: ref.howToRun="${s.howToRun}" requires opts.resolveCliDir`);let{command:u,baseArgs:p}=le(s,e.resolveCliDir()),x=s.extra?["--extra",Buffer.from(JSON.stringify(s.extra)).toString("base64")]:[],c=[...p,o,...x];return await new Promise((l,h)=>{let R=child_process.spawn(u,c,{cwd:process.cwd(),stdio:"pipe",windowsHide:true,shell:process.platform==="win32"&&/\.(cmd|bat)$/i.test(u)}),y=[],d=[],f=false,m=null,S=g=>{f||(f=true,m&&clearTimeout(m),h(g));},a=g=>{f||(f=true,m&&clearTimeout(m),l(g));};R.stdout.on("data",g=>{y.push(Buffer.from(g));}),R.stderr.on("data",g=>{d.push(Buffer.from(g));}),R.on("error",g=>{let v=g;v.stdout=Buffer.concat(y).toString("utf-8"),v.stderr=Buffer.concat(d).toString("utf-8"),S(v);}),R.on("close",g=>{let v=Buffer.concat(y).toString("utf-8"),b=Buffer.concat(d).toString("utf-8");if(g===0){a(v);return}let k=new Error(b.trim()||`executor exited with status ${g}`);k.stdout=v,k.stderr=b,S(k);}),n?.timeout&&n.timeout>0&&(m=setTimeout(()=>{R.kill();let g=new Error(`executor timed out after ${n.timeout}ms`);g.stdout=Buffer.concat(y).toString("utf-8"),g.stderr=Buffer.concat(d).toString("utf-8"),S(g);},n.timeout)),n?.input!==void 0?R.stdin.end(n.input):R.stdin.end();})}}}function B(e,t){if(process.platform!=="win32"){i__namespace.renameSync(e,t);return}let r=[10,20,40,80,160];for(let o=0;o<=r.length;o++)try{i__namespace.renameSync(e,t);return}catch(n){let s=n.code;if((s==="EPERM"||s==="EBUSY")&&o<r.length){Atomics.wait(new Int32Array(new SharedArrayBuffer(4)),0,0,r[o]);continue}throw n}}function U(e){function t(n){return w__namespace.join(e,...n.split("/"))}function r(n){return w__namespace.relative(e,n).replace(/\\/g,"/")}function o(n,s){if(i__namespace.existsSync(n))for(let u of i__namespace.readdirSync(n,{withFileTypes:true})){let p=w__namespace.join(n,u.name);if(u.isDirectory()){o(p,s);continue}u.isFile()&&s.push(r(p));}}return {read(n){let s=t(n);if(!i__namespace.existsSync(s))return null;try{return i__namespace.readFileSync(s,"utf-8")}catch{return null}},write(n,s){let u=t(n),p=`${u}.${process.pid}.${crypto.randomUUID()}.tmp`;i__namespace.mkdirSync(w__namespace.dirname(u),{recursive:true}),i__namespace.writeFileSync(p,s,"utf-8"),B(p,u);},exists(n){return i__namespace.existsSync(t(n))},remove(n){let s=t(n);try{i__namespace.existsSync(s)&&i__namespace.unlinkSync(s);}catch{}},readBytes(n){let s=t(n);if(!i__namespace.existsSync(s))return null;try{return new Uint8Array(i__namespace.readFileSync(s))}catch{return null}},writeBytes(n,s){let u=t(n),p=`${u}.${process.pid}.${crypto.randomUUID()}.tmp`;i__namespace.mkdirSync(w__namespace.dirname(u),{recursive:true}),i__namespace.writeFileSync(p,Buffer.from(s)),B(p,u);},listKeys(n){let s=[];o(e,s);let u=s.sort();return n?u.filter(p=>p.startsWith(n)):u},stat(n){let s=t(n);if(!i__namespace.existsSync(s))return null;try{let u=i__namespace.statSync(s);return {key:n,size:Number(u.size||0),updatedAt:new Date(u.mtimeMs).toISOString()}}catch{return null}},keyRef(n){return {kind:"fs-path",value:t(n)}},renameKey(n,s){let u=t(n);if(!i__namespace.existsSync(u))return false;let p=t(s);return i__namespace.mkdirSync(w__namespace.dirname(p),{recursive:true}),B(u,p),true}}}function Ie(){return {read(e){if(!i__namespace.existsSync(e))return null;try{return i__namespace.readFileSync(e,"utf-8")}catch{return null}},write(e,t){let r=`${e}.${process.pid}.${crypto.randomUUID()}.tmp`;i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:true}),i__namespace.writeFileSync(r,t,"utf-8"),B(r,e);},exists(e){return i__namespace.existsSync(e)},remove(e){try{i__namespace.existsSync(e)&&i__namespace.unlinkSync(e);}catch{}},readBytes(e){if(!i__namespace.existsSync(e))return null;try{return new Uint8Array(i__namespace.readFileSync(e))}catch{return null}},writeBytes(e,t){let r=`${e}.${process.pid}.${crypto.randomUUID()}.tmp`;i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:true}),i__namespace.writeFileSync(r,Buffer.from(t)),B(r,e);},stat(e){if(!i__namespace.existsSync(e))return null;try{let t=i__namespace.statSync(e);return {key:e,size:Number(t.size||0),updatedAt:new Date(t.mtimeMs).toISOString()}}catch{return null}},listKeys(e){return []},renameKey(e,t){return i__namespace.existsSync(e)?(i__namespace.mkdirSync(w__namespace.dirname(t),{recursive:true}),B(e,t),true):false}}}function D(e,t){let r=`${e}.${process.pid}.${crypto.randomUUID()}.tmp`;i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:true}),i__namespace.writeFileSync(r,JSON.stringify(t,null,2),"utf-8"),B(r,e);}function N(e){if(!i__namespace.existsSync(e))return null;try{return JSON.parse(i__namespace.readFileSync(e,"utf-8"))}catch{return null}}function X(e){return i__namespace.existsSync(e)?i__namespace.readdirSync(e).filter(t=>t.endsWith(".json")).sort().map(t=>w__namespace.join(e,t)):[]}function ee(e){return {id:e.id,body:e.body,enqueuedAt:e.enqueuedAt,attempt:e.attempt}}function Xt(e){return {...ee(e),leaseToken:String(e.leaseToken||""),leaseExpiresAt:String(e.leaseExpiresAt||"")}}function er(e){return {...ee(e),reason:e.reason}}function je(e){let t=w__namespace.join(e,"active"),r=w__namespace.join(e,"leased"),o=w__namespace.join(e,"done"),n=w__namespace.join(e,"dead"),s=w__namespace.join(e,"staged");for(let d of [t,r,o,n,s])i__namespace.mkdirSync(d,{recursive:true});let u=0;function p(d){let f=d.replace(/[:.]/g,"-"),m=String(u++).padStart(6,"0");return `${f}-${m}`}function x(d){let f=d.activeOrderKey||p(String(d.enqueuedAt||new Date().toISOString()));return w__namespace.join(t,`${f}-${d.id}.json`)}function c(d){return w__namespace.join(r,`${d}.json`)}function l(d){return w__namespace.join(o,`${d}.json`)}function h(d){return w__namespace.join(n,`${d}.json`)}function R(d){return w__namespace.join(s,`${d}.json`)}function y(){let d=Date.now();for(let f of X(r)){let m=N(f);if(!m?.leaseExpiresAt)continue;let S=Date.parse(m.leaseExpiresAt);if(Number.isNaN(S)||S>d)continue;let a={id:m.id,body:m.body,enqueuedAt:m.enqueuedAt,attempt:m.attempt,activeOrderKey:m.activeOrderKey};D(x(a),a);try{i__namespace.unlinkSync(f);}catch{}}}return {enqueue(d){let f={id:crypto.randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0};return f.activeOrderKey=p(f.enqueuedAt),D(x(f),f),ee(f)},enqueueMany(d){return d.map(f=>this.enqueue(f))},enqueueIfAbsent(d,f){y();for(let S of [t,r,s])for(let a of X(S))if(N(a)?.dedupKey===f)return null;let m={id:crypto.randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0,dedupKey:f};return m.activeOrderKey=p(m.enqueuedAt),D(x(m),m),ee(m)},lease(d){y();let f=Math.max(1,Math.floor(d?.max??1)),m=Math.max(1,Math.floor(d?.visibilityMs??6e4)),S=[];for(let a of X(t)){if(S.length>=f)break;let g=N(a);if(!g)continue;let v=c(g.id);try{B(a,v);}catch{continue}let b={...g,attempt:(Number(g.attempt)||0)+1,leaseToken:crypto.randomUUID(),leaseExpiresAt:new Date(Date.now()+m).toISOString()};D(v,b),S.push(Xt(b));}return S},ack(d,f){let m=c(d),S=N(m);if(!S||S.leaseToken!==f)return false;try{B(m,l(d));}catch{return false}return true},nack(d,f,m){let S=c(d),a=N(S);if(!a||a.leaseToken!==f)return false;let g={id:a.id,body:a.body,enqueuedAt:a.enqueuedAt,attempt:a.attempt,activeOrderKey:a.activeOrderKey};m?.dead?(g.reason=m.reason,D(h(d),g)):D(x(g),g);try{i__namespace.unlinkSync(S);}catch{}return true},peekActive(d){return y(),X(t).map(f=>N(f)).filter(f=>!!f).map(ee)},peekDeadLetter(d){return X(n).map(f=>N(f)).filter(f=>!!f).map(er)},stage(d,f){let m=f?.dedupKey;if(m){y();for(let a of [t,r,s])for(let g of X(a))if(N(g)?.dedupKey===m)return null}let S={id:crypto.randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0,...m?{dedupKey:m}:{}};return D(R(S.id),S),ee(S)},commitStaged(d){let f=R(d),m=N(f);if(!m)return false;let S=new Date().toISOString(),a={...m,attempt:0,enqueuedAt:S,activeOrderKey:p(S)};D(x(a),a);try{i__namespace.unlinkSync(f);}catch{}return true},discardStaged(d,f){let m=R(d),S=N(m);if(!S)return false;let a={id:S.id,body:S.body,enqueuedAt:S.enqueuedAt,attempt:S.attempt,reason:f};D(h(d),a);try{i__namespace.unlinkSync(m);}catch{}return true},peekStaged(d){return X(s).map(f=>N(f)).filter(f=>!!f).map(ee)}}}var Ee="__scratch-marker",Te="__scratch-config.json",tr=1440*60*1e3,rr=720*60*1e3,nr=500;function nt(e,t){if(!e)return t;let r=e.replace(/[^A-Za-z0-9._-]/g,"_");return r.length>0?r:t}function oe(e){i__namespace.mkdirSync(e,{recursive:true});let t=w__namespace.join(e,Ee),r=w__namespace.join(e,Te),o=!i__namespace.existsSync(t);if(o)try{i__namespace.writeFileSync(t,`scratch-store
4
4
  ${new Date().toISOString()}
@@ -8,5 +8,5 @@ ${new Date().toISOString()}
8
8
  `).filter(Boolean).map(o=>JSON.parse(o)):[]}return {append(r){let o={id:crypto.randomUUID(),payload:r};return i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:true}),i__namespace.appendFileSync(e,JSON.stringify(o)+`
9
9
  `,"utf-8"),o},readAll(){return t()},readAfter(r){let o=t();if(!r)return {entries:o,newCursor:o.length>0?o[o.length-1].id:null};let n=o.findIndex(u=>u.id===r),s=n===-1?o:o.slice(n+1);return {entries:s,newCursor:s.length>0?s[s.length-1].id:r}},clear(){i__namespace.existsSync(e)&&i__namespace.truncateSync(e,0);}}}function Ce(e){if(e==null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return `[${e.map(Ce).join(",")}]`;let t=e;return `{${Object.keys(t).sort().map(o=>`${JSON.stringify(o)}:${Ce(t[o])}`).join(",")}}`}function st(e){return crypto.createHash("sha256").update(Ce(e)).digest("hex")}function Be(e){let t=w__namespace.join(e,"board-journal.jsonl");return {readAllEntries(){if(!i__namespace.existsSync(t))return [];let r=i__namespace.readFileSync(t,"utf-8").trim();return r?r.split(`
10
10
  `).filter(Boolean).map(o=>JSON.parse(o)):[]},appendEntry(r){i__namespace.appendFileSync(t,JSON.stringify(r)+`
11
- `,"utf-8");},generateId(){return crypto.randomUUID()}}}function it(e){return {tryAcquire(){try{if(!i__namespace.existsSync(e)){i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:!0});try{i__namespace.writeFileSync(e,"{}",{flag:"wx"});}catch{}}return properLockfile.lockSync(e,{retries:0})}catch{return null}}}}function z(e){return {status:"success",data:e}}function Q(e){return {status:"fail",error:e}}function re(e){return {status:"error",error:e instanceof Error?e.message:String(e)}}function ne(e){return e&&typeof e=="object"&&!Array.isArray(e)?e:{}}function ar(e,t={}){let r=()=>chunkWRMOGPRG_cjs.b(e.kvStorage("config")),o=t.unsupportedLabel??"hosted async runtime";async function n(){return t.taskExecutorRef?t.taskExecutorRef:await r().readTaskExecutorRef().catch(()=>{})}async function s(y,d,f){let m=await n();if(!m||!t.invokeExecutor)throw new Error(`${y} is not supported on the ${o} yet`);let a=(await t.invokeExecutor(m,y,{...d!==void 0?{input:typeof d=="string"?d:JSON.stringify(d)}:{},...f!==void 0?{timeout:f}:{}})).trim();return a?ne(JSON.parse(a)):{}}async function u(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("validateCardPreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=chunkNLC4FN7V_cjs.a(f),a=Array.isArray(f.source_defs)&&f.source_defs.length>0,g=[...S.issues];if(a)if(t.invokeExecutor&&await n())for(let v of f.source_defs){let b=typeof v.bindTo=="string"?v.bindTo:"(unknown)";try{let k=await s("validate-source-def",v,1e4);if(k.ok!==!0&&Array.isArray(k.errors))for(let A of k.errors)typeof A=="string"&&A&&g.push(`source "${b}": ${A}`);}catch(k){g.push(`source "${b}": executor validate-source-def failed \u2014 ${k instanceof Error?k.message:String(k)}`);}}else await n()&&g.push(`executor-backed source_def preflight is not supported on the ${o} yet`);return z({cardId:m,isValid:g.length===0,issues:g})}catch(d){return re(d)}}function p(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("evalCardCompute requires a JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=d["mock-fetched-sources"]??{},a=d["mock-requires"]??{},g=f.compute;if(!g||!Array.isArray(g)||g.length===0)return z({cardId:m,ok:!0,computed_values:{},errors:[]});let v={id:m,card_data:f.card_data??{},requires:a,source_defs:f.source_defs,compute:g},b=chunkUG55PF75_cjs.a.runSync(v,{sourcesData:S});return z({cardId:m,ok:(b.errors??[]).length===0,computed_values:b.node.computed_values??{},errors:b.errors??[]})}catch(d){return re(d)}}async function x(y){return Q(`${y} is not supported on the ${o} yet`)}async function c(){try{return t.invokeExecutor&&await n()?z(await s("describe-capabilities",void 0,1e4)):await x("describeTaskExecutorCapabilities")}catch(y){return re(y)}}async function l(y){try{if(!t.invokeExecutor||!await n())return await x("probeSourcePreflight");if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("probeSourcePreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=ne(d["mock-projections"]??{}),S=y.params?.sourceIdx,a=Array.isArray(f.source_defs)?f.source_defs:[];if(S===void 0)return Q("probeSourcePreflight requires params.sourceIdx");if(S<0||S>=a.length)return Q(`sourceIdx ${S} out of range (card has ${a.length} source(s))`);let g=a[S],v=typeof g.bindTo=="string"?g.bindTo:"source",b=await s("probe-source-preflight",{...g,_projections:m},g.timeout??6e4);return b.ok!==!0?Q(typeof b.error=="string"?b.error:"Preflight probe failed"):z({bindTo:v,reachable:b.reachable,latencyMs:b.latencyMs,...typeof b.note=="string"?{note:b.note}:{}})}catch(d){return re(d)}}async function h(y){try{if(!t.invokeExecutor||!await n())return await x("runSourcePreflight");if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("runSourcePreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=ne(d["mock-projections"]??{}),S=y.params?.sourceIdx,a=Array.isArray(f.source_defs)?f.source_defs:[];if(S===void 0)return Q("runSourcePreflight requires params.sourceIdx");if(S<0||S>=a.length)return Q(`sourceIdx ${S} out of range (card has ${a.length} source(s))`);let g=a[S],v=typeof g.bindTo=="string"?g.bindTo:"source",b=await s("run-source-preflight",{...g,_projections:m},g.timeout??6e4);return b.ok!==!0?z({bindTo:v,ok:!1,result:null,issues:[typeof b.error=="string"?b.error:"Preflight run failed"]}):z({bindTo:v,ok:!0,result:Object.prototype.hasOwnProperty.call(b,"resultValue")?b.resultValue:null,issues:[]})}catch(d){return re(d)}}async function R(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("simulateCardCycle requires a JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=ne(d["mock-fetched-sources"]??{}),a=ne(d["mock-requires"]??{}),g=await u({body:{"card-content":f}}),v=g.status==="success"?{isValid:g.data.isValid,issues:g.data.issues}:{isValid:!1,issues:[g.status==="fail"?g.error:"internal error"]},b=Array.isArray(f.source_defs)?f.source_defs:[],k=ne(f.card_data??{}),A=[],F=[];if(b.length>0){A=chunkUG55PF75_cjs.a.enrichSourcesSync(b,{card_data:k,requires:a});for(let I of A){let P=I.projections,W=I._projections;if(P&&W){for(let $ of Object.keys(P))if(W[$]===void 0){let ut=typeof I.bindTo=="string"?I.bindTo:"(unknown)";F.push({bindTo:ut,key:$,error:`Projection "${$}" resolved to undefined`});}}}}let E=[],M={...S};for(let I=0;I<A.length;I+=1){let P=A[I],W=typeof P.bindTo=="string"?P.bindTo:`source_${I}`;if(!t.invokeExecutor||!await n()){E.push({bindTo:W,skipped:!0,error:"No task executor configured"});continue}try{let $=await s("run-source-preflight",P,P.timeout??6e4);$.ok===!0&&!Object.prototype.hasOwnProperty.call(S,W)&&Object.prototype.hasOwnProperty.call($,"resultValue")&&(M[W]=$.resultValue),E.push({bindTo:W,reachable:$.reachable,latencyMs:$.latencyMs,...$.ok===!0?{}:{error:typeof $.error=="string"?$.error:"Preflight run failed"}});}catch{E.push({bindTo:W,skipped:!0,error:"Executor does not support run-source-preflight"});}}let K=f.compute,te={},G=[];if(K&&Array.isArray(K)&&K.length>0){let I={id:m,card_data:k,requires:a,source_defs:f.source_defs,compute:K},P=chunkUG55PF75_cjs.a.runSync(I,{sourcesData:M});te=P.node.computed_values??{},G=P.errors??[];}return z({cardId:m,ok:v.isValid&&F.length===0&&G.length===0&&E.every(I=>!I.error),validation:v,source_probes:E,projection_errors:F,fetched_sources:M,computed_values:te,compute_errors:G})}catch(d){return re(d)}}return {describeTaskExecutorCapabilities:c,validateCardPreflight:u,evalCardCompute:p,probeSourcePreflight:l,runSourcePreflight:h,simulateCardCycle:R}}function sn(){return {async invoke(e,t){if(e.howToRun!=="local-node")return {dispatched:false,error:`createNodeSpawnInvocationAdapter: unsupported howToRun "${e.howToRun}"`};let r="";try{let s=e.whatToRun;r=L(s);}catch{r="";}if(!r)return {dispatched:false,error:"createNodeSpawnInvocationAdapter: could not resolve executable path from whatToRun"};let o={...t},n=Buffer.from(JSON.stringify(o)).toString("base64");try{return child_process.spawn(process.execPath,[r,"--boardId",String(t.boardId??""),"--cardId",String(t.cardId??""),"--extraEncJson",n],{stdio:"ignore",windowsHide:!0}).unref(),{dispatched:!0}}catch(s){return {dispatched:false,error:s instanceof Error?s.message:String(s)}}},async describe(e){if(e.howToRun!=="local-node")return null;let t="";try{let r=e.whatToRun;t=L(r);}catch{t="";}if(!t)return null;try{let r=child_process.spawnSync(process.execPath,[t,"describe"],{timeout:5e3,encoding:"utf-8",windowsHide:!0});return r.status!==0?null:JSON.parse(String(r.stdout).trim())}catch{return null}}}}var dr=".board.lock";function at(e,t){if(!e||!t)return false;let r=String(e).replace(/[\\/]+$/,"").split(/[\\/]+/).filter(Boolean);return r.length>0&&r[r.length-1]===t}function lr(e,t){return typeof e=="string"?{cliDir:e,opts:t}:{cliDir:void 0,opts:e}}function fr(e,t){return typeof e=="string"?{cliDir:e,opts:t}:{cliDir:void 0,opts:e}}function ct(e){if(e)return e;let t=Je((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('board-live-cards-node.cjs', document.baseURI).href))),r=[t,C(t,"..","cli","node"),C(t,"..","..","cli","node")];for(let o of r)try{return Ve(o),o}catch{}throw new Error(`createFsBoardPlatformAdapter: could not resolve a public CLI directory from module dir ${t}`)}function pr(e,t,r){let{cliDir:o,opts:n}=lr(t,r),s=e.value,u=null,p,x=null,c;function l(){return c||(c=ct(o)),c}function h(a){let g=n?.queueStoreRef;if(!g)throw new Error(`createFsBoardPlatformAdapter: ${a} requires opts.queueStoreRef`);return g}function R(a){let g=n?.boardRuntimeStoreRef;if(!g)throw new Error(`createFsBoardPlatformAdapter: ${a} requires opts.boardRuntimeStoreRef`);return g}let y=n?.callbackTransport??chunkYXKWIPQM_cjs.g({notifyChannel:n?.notifyChannel,boardRuntimeStoreRef:n?.boardRuntimeStoreRef,queueStoreRef:n?.queueStoreRef}),d;function f(a){return d.queueStorageForRef(h(`internal lane "${a}"`),a)}function m(a){return chunkGPCMBPLK_cjs.a(f(a))}function S(){if(n?.suppressSpawn||u)return;let a=xe({id:"task-executor",workerStore:m("task-executor"),handleRequest:async(g,v)=>{let b=await Z(v.ref,v.args,{cliDir:l(),cwd:process.cwd(),label:"fsBoardAdapter.boardWorker"});if(b.result!=="success"){let k=typeof b.data?.error=="string"?b.data.error:b.error;throw new Error(k||b.result)}}});u=de(a).catch(g=>{n?.onWarn?.(`[board-worker] in-process queue drain failed: ${g instanceof Error?g.message:String(g)}`);}).finally(()=>{u=null,f("task-executor").peekActive().length>0&&S();});}return d={kvStorage:a=>se(C(s,`.${a}`)),blobStorage:a=>a?U(C(s,a)):U(s),blobStorageForRef:a=>U(chunkVQCIOKJV_cjs.b(a).value),chatStorageForRef:a=>gr(chunkVQCIOKJV_cjs.b(a).value),queueStorageForRef:(a,g)=>je(C(chunkVQCIOKJV_cjs.b(a).value,g)),scratchStorage:()=>oe(C(s,".tmp")),scratchStorageForRef:a=>oe(chunkVQCIOKJV_cjs.b(a).value),archiveFactory:()=>ge(C(s,"archive")),archiveFactoryForRef:a=>ge(chunkVQCIOKJV_cjs.b(a).value),journalAdapter:()=>Be(s),journalAdapterForRef:a=>Be(chunkVQCIOKJV_cjs.b(a).value),lock:it(C(s,dr)),callbackTransport:y,async dispatchExecution(a,g){let v=!!g.output?.ref;if(a.howToRun==="queue-storage")try{let k=m("task-executor"),A=typeof a.extra?.boardId=="string"?a.extra.boardId:void 0;if(v)return k.enqueueRequest({boardId:A,ref:a,args:g}),{dispatched:!0};let F=g.source_def?.bindTo??ue().slice(0,8),E=oe(C(s,".tmp")),M=E.create(JSON.stringify(g,null,2),`exec-in-${F}`,".json"),K=E.getUniqueKey(`exec-out-${F}`,".json"),te=E.getUniqueKey(`exec-err-${F}`,".txt"),G=chunkVQCIOKJV_cjs.a(E.keyRef(M)),I=chunkVQCIOKJV_cjs.a(E.keyRef(K)),P=chunkVQCIOKJV_cjs.a(E.keyRef(te));return k.enqueueRequest({boardId:A,ref:a,args:{subcommand:"run-source-fetch",inRef:G,outRef:I,errRef:P}}),{dispatched:!0}}catch(k){return {dispatched:false,error:k instanceof Error?k.message:String(k)}}if(v&&(a.howToRun==="http:post"||a.howToRun==="in-process-loop"))try{if(a.howToRun==="http:post"){let F=L(a.whatToRun),E=await fetch(F,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,...a.extra?{extra:a.extra}:{}})});if(!E.ok){let M=await E.text().catch(()=>"");return {dispatched:!1,error:`HTTP ${E.status}: ${M}`}}return {dispatched:!0}}let k=await Z(a,g,{cwd:process.cwd(),label:"dispatchExecution.directHostedWorker"});return k.result==="success"?{dispatched:!0}:{dispatched:!1,error:(typeof k.data?.error=="string"?k.data.error:k.error)||k.result}}catch(k){return {dispatched:false,error:k instanceof Error?k.message:String(k)}}let b=a.howToRun==="local-node"||a.howToRun==="local-process"||a.howToRun==="local-python"||a.howToRun==="built-in";if(n?.suppressSpawn&&b)return {dispatched:false};try{let k=g.source_def?.bindTo??ue().slice(0,8),A=oe(C(s,".tmp")),F=A.create(JSON.stringify(g,null,2),`exec-in-${k}`,".json"),E=A.getUniqueKey(`exec-out-${k}`,".json"),M=A.getUniqueKey(`exec-err-${k}`,".txt"),K=chunkVQCIOKJV_cjs.a(A.keyRef(F)),te=chunkVQCIOKJV_cjs.a(A.keyRef(E)),G=chunkVQCIOKJV_cjs.a(A.keyRef(M)),I=m("task-executor"),P=typeof a.extra?.boardId=="string"?a.extra.boardId:void 0;return I.enqueueRequest({boardId:P,ref:a,args:{subcommand:"run-source-fetch",inRef:K,outRef:te,errRef:G}}),S(),{dispatched:!0}}catch(k){let A=k instanceof Error?k.message:String(k);try{let F=ge(C(s,"archive")),E=new Date().toISOString().replace(/[:.]/g,"-"),M=g.source_def?.bindTo??"unknown";F.blob("exec-failures").write(`${E}-${M}.json`,JSON.stringify({error:A,args:g,ref:a,at:new Date().toISOString()},null,2));}catch{}return {dispatched:false,error:A}}},supportsDirectSourceOutput(a){return a.howToRun==="queue-storage"||a.howToRun==="http:post"||a.howToRun==="in-process-loop"},resolveBlob(a){let g=Ne(a.value)?Ie().read(a.value):U(s).read(a.value);if(g===null)throw new Error(`resolveBlob: blob not found: ::${a.kind}::${a.value}`);return g},hashFn:st,genId:()=>Qe(`${Date.now()}-${Math.random()}`).slice(0,32),kvStorageForRef:a=>se(chunkVQCIOKJV_cjs.b(a).value),requestProcessAccumulated(){if(n?.suppressSpawn||x)return;let a=this,g=p??=chunkYXKWIPQM_cjs.y(e,a,{boardRuntimeStoreRef:R("requestProcessAccumulated")}),v=we({id:"process-accumulated",queueStorage:f("process-accumulated"),handleMessage:async()=>{let b=await g.processAccumulatedEvents({});if(b.status!=="success")throw new Error(b.error||`processAccumulatedEvents returned ${b.status}`)}});x=de(v).catch(b=>{n?.onWarn?.(`[process-accumulated] in-process queue drain failed: ${b instanceof Error?b.message:String(b)}`);}).finally(()=>{x=null,f("process-accumulated").peekActive().length>0&&a.requestProcessAccumulated?.();});},publishBoardChangeNotifications(a){if(!n?.notifyChannel||a.length===0)return;let g=a.map(v=>({id:ue(),ts:new Date().toISOString(),boardRef:chunkVQCIOKJV_cjs.a(e),notification:v}));Ue(n.notifyChannel,g,n.onWarn);},onWarn:n?.onWarn},d}function an(e,t,r){let{cliDir:o,opts:n}=fr(t,r),s,u=()=>(s||(s=ct(o)),s),p=pr(e,o,n),x=Ae({resolveCliDir:u,...n?.resolveRef?{resolveRef:n.resolveRef}:{}});return {...p,invokeExecutor:x.invokeExecutor,validateSchema(c){let l=chunkJHXRGPL7_cjs.d(c);return {ok:l.errors.length===0,errors:l.errors}},absoluteBlob:Ie()}}function cn(e,t={}){let r=t.chatsSubdir??"chats",o=t.kvSubdir??".kv",n=o?[o,"chat"]:["chat"],s=r&&!at(e,r)?C(e,r):e,u=se(C(e,...n));return chunkMCPADH33_cjs.a(p=>{let c=`${String(p).replace(/[^a-zA-Z0-9_-]/g,"_")}.jsonl`,l=C(s,c);return me(l)},u)}function gr(e){return chunkMCPADH33_cjs.a(t=>{let o=`${String(t).replace(/[^a-zA-Z0-9_-]/g,"_")}.jsonl`;return me(C(e,"journal",o))},se(C(e,"kv")))}function un(e,t={}){let r=t.filesSubdir??"files",o=r&&!at(e,r)?C(e,r):e;return chunkNBJTYAYN_cjs.a(U(o))}function dn(e){try{let t=JSON.parse(Buffer.from(e,"base64url").toString());return typeof t.br=="string"?t.br:null}catch{return null}}Object.defineProperty(exports,"createChatStorage",{enumerable:true,get:function(){return chunkMCPADH33_cjs.a}});Object.defineProperty(exports,"createInMemoryChatStorage",{enumerable:true,get:function(){return chunkMCPADH33_cjs.c}});Object.defineProperty(exports,"createArtifactsStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.a}});Object.defineProperty(exports,"createCardFileMetadataStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.c}});Object.defineProperty(exports,"createFileArtifactsStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.b}});Object.defineProperty(exports,"createBoardWorkerStore",{enumerable:true,get:function(){return chunkGPCMBPLK_cjs.a}});Object.defineProperty(exports,"createQueueLaneRegistry",{enumerable:true,get:function(){return chunkGPCMBPLK_cjs.b}});Object.defineProperty(exports,"BOARD_GRAPH_KEY",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.n}});Object.defineProperty(exports,"EMPTY_CONFIG",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.u}});Object.defineProperty(exports,"SNAPSHOT_SCHEMA_VERSION_V1",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.m}});Object.defineProperty(exports,"createBoardLiveCardsNonCorePublic",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.z}});Object.defineProperty(exports,"createBoardLiveCardsPublic",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.y}});Object.defineProperty(exports,"createCardStore",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.l}});Object.defineProperty(exports,"createHttpBoardCallbackTransport",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.e}});Object.defineProperty(exports,"createInProcessBoardCallbackTransport",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.f}});Object.defineProperty(exports,"createLocalNodeBoardCallbackTransport",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.g}});Object.defineProperty(exports,"executionRefFromScriptPath",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.a}});Object.defineProperty(exports,"parseExecutionRef",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.c}});Object.defineProperty(exports,"serializeExecutionRef",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.b}});Object.defineProperty(exports,"parseRef",{enumerable:true,get:function(){return chunkVQCIOKJV_cjs.b}});Object.defineProperty(exports,"serializeRef",{enumerable:true,get:function(){return chunkVQCIOKJV_cjs.a}});Object.defineProperty(exports,"createBoardLiveCardsMcp",{enumerable:true,get:function(){return chunkIRGTOCEU_cjs.a}});Object.defineProperty(exports,"createCardStorePublic",{enumerable:true,get:function(){return chunk5XLFPPTY_cjs.a}});Object.defineProperty(exports,"createQueueStoragePublic",{enumerable:true,get:function(){return chunkSDJ3747Q_cjs.a}});Object.defineProperty(exports,"createArtifactsStorePublic",{enumerable:true,get:function(){return chunkP7ZCDICS_cjs.a}});exports.buildLocalBaseSpec=le;exports.createBoardWorkerQueueLane=xe;exports.createExecutionRefInvoker=Ut;exports.createFsBlobStorage=U;exports.createFsBoardChatStorage=cn;exports.createFsBoardFileArtifactsStore=un;exports.createFsBoardNonCorePlatformAdapter=an;exports.createFsBoardPlatformAdapter=pr;exports.createFsChatStorageForRefRoot=gr;exports.createFsQueueStorage=je;exports.createHostedAsyncBoardNonCorePublic=ar;exports.createNodeSpawnInvocationAdapter=sn;exports.createNonCoreExecutorDispatcher=Ae;exports.createQueueStorageLane=we;exports.decodeBoardRefFromToken=dn;exports.drainQueueLaneToIdle=de;exports.evaluateArgsMassaging=ke;exports.invokeExecutionRef=Z;exports.invokeExecutionRefSync=ve;exports.invokeRefSync=zt;exports.registerInProcessExecutionHandler=Dt;exports.resolveWhatToRunValue=L;exports.resolveYamlFlowCliPath=Xe;exports.startQueueLaneRunner=Ye;exports.startQueueLaneRunners=Ot;exports.unregisterInProcessExecutionHandler=Kt;//# sourceMappingURL=board-live-cards-node.cjs.map
11
+ `,"utf-8");},generateId(){return crypto.randomUUID()}}}function it(e){return {tryAcquire(){try{if(!i__namespace.existsSync(e)){i__namespace.mkdirSync(w__namespace.dirname(e),{recursive:!0});try{i__namespace.writeFileSync(e,"{}",{flag:"wx"});}catch{}}return properLockfile.lockSync(e,{retries:0})}catch{return null}}}}function z(e){return {status:"success",data:e}}function Q(e){return {status:"fail",error:e}}function re(e){return {status:"error",error:e instanceof Error?e.message:String(e)}}function ne(e){return e&&typeof e=="object"&&!Array.isArray(e)?e:{}}function ar(e,t={}){let r=()=>chunkWRMOGPRG_cjs.b(e.kvStorage("config")),o=t.unsupportedLabel??"hosted async runtime";async function n(){return t.taskExecutorRef?t.taskExecutorRef:await r().readTaskExecutorRef().catch(()=>{})}async function s(y,d,f){let m=await n();if(!m||!t.invokeExecutor)throw new Error(`${y} is not supported on the ${o} yet`);let a=(await t.invokeExecutor(m,y,{...d!==void 0?{input:typeof d=="string"?d:JSON.stringify(d)}:{},...f!==void 0?{timeout:f}:{}})).trim();return a?ne(JSON.parse(a)):{}}async function u(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("validateCardPreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=chunkCPJXGK2T_cjs.a(f),a=Array.isArray(f.source_defs)&&f.source_defs.length>0,g=[...S.issues];if(a)if(t.invokeExecutor&&await n())for(let v of f.source_defs){let b=typeof v.bindTo=="string"?v.bindTo:"(unknown)";try{let k=await s("validate-source-def",v,1e4);if(k.ok!==!0&&Array.isArray(k.errors))for(let A of k.errors)typeof A=="string"&&A&&g.push(`source "${b}": ${A}`);}catch(k){g.push(`source "${b}": executor validate-source-def failed \u2014 ${k instanceof Error?k.message:String(k)}`);}}else await n()&&g.push(`executor-backed source_def preflight is not supported on the ${o} yet`);return z({cardId:m,isValid:g.length===0,issues:g})}catch(d){return re(d)}}function p(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("evalCardCompute requires a JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=d["mock-fetched-sources"]??{},a=d["mock-requires"]??{},g=f.compute;if(!g||!Array.isArray(g)||g.length===0)return z({cardId:m,ok:!0,computed_values:{},errors:[]});let v={id:m,card_data:f.card_data??{},requires:a,source_defs:f.source_defs,compute:g},b=chunkQBEQL4TL_cjs.a.runSync(v,{sourcesData:S});return z({cardId:m,ok:(b.errors??[]).length===0,computed_values:b.node.computed_values??{},errors:b.errors??[]})}catch(d){return re(d)}}async function x(y){return Q(`${y} is not supported on the ${o} yet`)}async function c(){try{return t.invokeExecutor&&await n()?z(await s("describe-capabilities",void 0,1e4)):await x("describeTaskExecutorCapabilities")}catch(y){return re(y)}}async function l(y){try{if(!t.invokeExecutor||!await n())return await x("probeSourcePreflight");if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("probeSourcePreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=ne(d["mock-projections"]??{}),S=y.params?.sourceIdx,a=Array.isArray(f.source_defs)?f.source_defs:[];if(S===void 0)return Q("probeSourcePreflight requires params.sourceIdx");if(S<0||S>=a.length)return Q(`sourceIdx ${S} out of range (card has ${a.length} source(s))`);let g=a[S],v=typeof g.bindTo=="string"?g.bindTo:"source",b=await s("probe-source-preflight",{...g,_projections:m},g.timeout??6e4);return b.ok!==!0?Q(typeof b.error=="string"?b.error:"Preflight probe failed"):z({bindTo:v,reachable:b.reachable,latencyMs:b.latencyMs,...typeof b.note=="string"?{note:b.note}:{}})}catch(d){return re(d)}}async function h(y){try{if(!t.invokeExecutor||!await n())return await x("runSourcePreflight");if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("runSourcePreflight requires card JSON object in body");let d=y.body,f=d["card-content"]??d,m=ne(d["mock-projections"]??{}),S=y.params?.sourceIdx,a=Array.isArray(f.source_defs)?f.source_defs:[];if(S===void 0)return Q("runSourcePreflight requires params.sourceIdx");if(S<0||S>=a.length)return Q(`sourceIdx ${S} out of range (card has ${a.length} source(s))`);let g=a[S],v=typeof g.bindTo=="string"?g.bindTo:"source",b=await s("run-source-preflight",{...g,_projections:m},g.timeout??6e4);return b.ok!==!0?z({bindTo:v,ok:!1,result:null,issues:[typeof b.error=="string"?b.error:"Preflight run failed"]}):z({bindTo:v,ok:!0,result:Object.prototype.hasOwnProperty.call(b,"resultValue")?b.resultValue:null,issues:[]})}catch(d){return re(d)}}async function R(y){try{if(!y.body||typeof y.body!="object"||Array.isArray(y.body))return Q("simulateCardCycle requires a JSON object in body");let d=y.body,f=d["card-content"]??d,m=typeof f.id=="string"?f.id:"(unknown)",S=ne(d["mock-fetched-sources"]??{}),a=ne(d["mock-requires"]??{}),g=await u({body:{"card-content":f}}),v=g.status==="success"?{isValid:g.data.isValid,issues:g.data.issues}:{isValid:!1,issues:[g.status==="fail"?g.error:"internal error"]},b=Array.isArray(f.source_defs)?f.source_defs:[],k=ne(f.card_data??{}),A=[],F=[];if(b.length>0){A=chunkQBEQL4TL_cjs.a.enrichSourcesSync(b,{card_data:k,requires:a});for(let I of A){let P=I.projections,W=I._projections;if(P&&W){for(let $ of Object.keys(P))if(W[$]===void 0){let ut=typeof I.bindTo=="string"?I.bindTo:"(unknown)";F.push({bindTo:ut,key:$,error:`Projection "${$}" resolved to undefined`});}}}}let E=[],M={...S};for(let I=0;I<A.length;I+=1){let P=A[I],W=typeof P.bindTo=="string"?P.bindTo:`source_${I}`;if(!t.invokeExecutor||!await n()){E.push({bindTo:W,skipped:!0,error:"No task executor configured"});continue}try{let $=await s("run-source-preflight",P,P.timeout??6e4);$.ok===!0&&!Object.prototype.hasOwnProperty.call(S,W)&&Object.prototype.hasOwnProperty.call($,"resultValue")&&(M[W]=$.resultValue),E.push({bindTo:W,reachable:$.reachable,latencyMs:$.latencyMs,...$.ok===!0?{}:{error:typeof $.error=="string"?$.error:"Preflight run failed"}});}catch{E.push({bindTo:W,skipped:!0,error:"Executor does not support run-source-preflight"});}}let K=f.compute,te={},G=[];if(K&&Array.isArray(K)&&K.length>0){let I={id:m,card_data:k,requires:a,source_defs:f.source_defs,compute:K},P=chunkQBEQL4TL_cjs.a.runSync(I,{sourcesData:M});te=P.node.computed_values??{},G=P.errors??[];}return z({cardId:m,ok:v.isValid&&F.length===0&&G.length===0&&E.every(I=>!I.error),validation:v,source_probes:E,projection_errors:F,fetched_sources:M,computed_values:te,compute_errors:G})}catch(d){return re(d)}}return {describeTaskExecutorCapabilities:c,validateCardPreflight:u,evalCardCompute:p,probeSourcePreflight:l,runSourcePreflight:h,simulateCardCycle:R}}function sn(){return {async invoke(e,t){if(e.howToRun!=="local-node")return {dispatched:false,error:`createNodeSpawnInvocationAdapter: unsupported howToRun "${e.howToRun}"`};let r="";try{let s=e.whatToRun;r=L(s);}catch{r="";}if(!r)return {dispatched:false,error:"createNodeSpawnInvocationAdapter: could not resolve executable path from whatToRun"};let o={...t},n=Buffer.from(JSON.stringify(o)).toString("base64");try{return child_process.spawn(process.execPath,[r,"--boardId",String(t.boardId??""),"--cardId",String(t.cardId??""),"--extraEncJson",n],{stdio:"ignore",windowsHide:!0}).unref(),{dispatched:!0}}catch(s){return {dispatched:false,error:s instanceof Error?s.message:String(s)}}},async describe(e){if(e.howToRun!=="local-node")return null;let t="";try{let r=e.whatToRun;t=L(r);}catch{t="";}if(!t)return null;try{let r=child_process.spawnSync(process.execPath,[t,"describe"],{timeout:5e3,encoding:"utf-8",windowsHide:!0});return r.status!==0?null:JSON.parse(String(r.stdout).trim())}catch{return null}}}}var dr=".board.lock";function at(e,t){if(!e||!t)return false;let r=String(e).replace(/[\\/]+$/,"").split(/[\\/]+/).filter(Boolean);return r.length>0&&r[r.length-1]===t}function lr(e,t){return typeof e=="string"?{cliDir:e,opts:t}:{cliDir:void 0,opts:e}}function fr(e,t){return typeof e=="string"?{cliDir:e,opts:t}:{cliDir:void 0,opts:e}}function ct(e){if(e)return e;let t=Je((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('board-live-cards-node.cjs', document.baseURI).href))),r=[t,C(t,"..","cli","node"),C(t,"..","..","cli","node")];for(let o of r)try{return Ve(o),o}catch{}throw new Error(`createFsBoardPlatformAdapter: could not resolve a public CLI directory from module dir ${t}`)}function pr(e,t,r){let{cliDir:o,opts:n}=lr(t,r),s=e.value,u=null,p,x=null,c;function l(){return c||(c=ct(o)),c}function h(a){let g=n?.queueStoreRef;if(!g)throw new Error(`createFsBoardPlatformAdapter: ${a} requires opts.queueStoreRef`);return g}function R(a){let g=n?.boardRuntimeStoreRef;if(!g)throw new Error(`createFsBoardPlatformAdapter: ${a} requires opts.boardRuntimeStoreRef`);return g}let y=n?.callbackTransport??chunkVNLMJEIX_cjs.g({notifyChannel:n?.notifyChannel,boardRuntimeStoreRef:n?.boardRuntimeStoreRef,queueStoreRef:n?.queueStoreRef}),d;function f(a){return d.queueStorageForRef(h(`internal lane "${a}"`),a)}function m(a){return chunkGPCMBPLK_cjs.a(f(a))}function S(){if(n?.suppressSpawn||u)return;let a=xe({id:"task-executor",workerStore:m("task-executor"),handleRequest:async(g,v)=>{let b=await Z(v.ref,v.args,{cliDir:l(),cwd:process.cwd(),label:"fsBoardAdapter.boardWorker"});if(b.result!=="success"){let k=typeof b.data?.error=="string"?b.data.error:b.error;throw new Error(k||b.result)}}});u=de(a).catch(g=>{n?.onWarn?.(`[board-worker] in-process queue drain failed: ${g instanceof Error?g.message:String(g)}`);}).finally(()=>{u=null,f("task-executor").peekActive().length>0&&S();});}return d={kvStorage:a=>se(C(s,`.${a}`)),blobStorage:a=>a?U(C(s,a)):U(s),blobStorageForRef:a=>U(chunkVQCIOKJV_cjs.b(a).value),chatStorageForRef:a=>gr(chunkVQCIOKJV_cjs.b(a).value),queueStorageForRef:(a,g)=>je(C(chunkVQCIOKJV_cjs.b(a).value,g)),scratchStorage:()=>oe(C(s,".tmp")),scratchStorageForRef:a=>oe(chunkVQCIOKJV_cjs.b(a).value),archiveFactory:()=>ge(C(s,"archive")),archiveFactoryForRef:a=>ge(chunkVQCIOKJV_cjs.b(a).value),journalAdapter:()=>Be(s),journalAdapterForRef:a=>Be(chunkVQCIOKJV_cjs.b(a).value),lock:it(C(s,dr)),callbackTransport:y,async dispatchExecution(a,g){let v=!!g.output?.ref;if(a.howToRun==="queue-storage")try{let k=m("task-executor"),A=typeof a.extra?.boardId=="string"?a.extra.boardId:void 0;if(v)return k.enqueueRequest({boardId:A,ref:a,args:g}),{dispatched:!0};let F=g.source_def?.bindTo??ue().slice(0,8),E=oe(C(s,".tmp")),M=E.create(JSON.stringify(g,null,2),`exec-in-${F}`,".json"),K=E.getUniqueKey(`exec-out-${F}`,".json"),te=E.getUniqueKey(`exec-err-${F}`,".txt"),G=chunkVQCIOKJV_cjs.a(E.keyRef(M)),I=chunkVQCIOKJV_cjs.a(E.keyRef(K)),P=chunkVQCIOKJV_cjs.a(E.keyRef(te));return k.enqueueRequest({boardId:A,ref:a,args:{subcommand:"run-source-fetch",inRef:G,outRef:I,errRef:P}}),{dispatched:!0}}catch(k){return {dispatched:false,error:k instanceof Error?k.message:String(k)}}if(v&&(a.howToRun==="http:post"||a.howToRun==="in-process-loop"))try{if(a.howToRun==="http:post"){let F=L(a.whatToRun),E=await fetch(F,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,...a.extra?{extra:a.extra}:{}})});if(!E.ok){let M=await E.text().catch(()=>"");return {dispatched:!1,error:`HTTP ${E.status}: ${M}`}}return {dispatched:!0}}let k=await Z(a,g,{cwd:process.cwd(),label:"dispatchExecution.directHostedWorker"});return k.result==="success"?{dispatched:!0}:{dispatched:!1,error:(typeof k.data?.error=="string"?k.data.error:k.error)||k.result}}catch(k){return {dispatched:false,error:k instanceof Error?k.message:String(k)}}let b=a.howToRun==="local-node"||a.howToRun==="local-process"||a.howToRun==="local-python"||a.howToRun==="built-in";if(n?.suppressSpawn&&b)return {dispatched:false};try{let k=g.source_def?.bindTo??ue().slice(0,8),A=oe(C(s,".tmp")),F=A.create(JSON.stringify(g,null,2),`exec-in-${k}`,".json"),E=A.getUniqueKey(`exec-out-${k}`,".json"),M=A.getUniqueKey(`exec-err-${k}`,".txt"),K=chunkVQCIOKJV_cjs.a(A.keyRef(F)),te=chunkVQCIOKJV_cjs.a(A.keyRef(E)),G=chunkVQCIOKJV_cjs.a(A.keyRef(M)),I=m("task-executor"),P=typeof a.extra?.boardId=="string"?a.extra.boardId:void 0;return I.enqueueRequest({boardId:P,ref:a,args:{subcommand:"run-source-fetch",inRef:K,outRef:te,errRef:G}}),S(),{dispatched:!0}}catch(k){let A=k instanceof Error?k.message:String(k);try{let F=ge(C(s,"archive")),E=new Date().toISOString().replace(/[:.]/g,"-"),M=g.source_def?.bindTo??"unknown";F.blob("exec-failures").write(`${E}-${M}.json`,JSON.stringify({error:A,args:g,ref:a,at:new Date().toISOString()},null,2));}catch{}return {dispatched:false,error:A}}},supportsDirectSourceOutput(a){return a.howToRun==="queue-storage"||a.howToRun==="http:post"||a.howToRun==="in-process-loop"},resolveBlob(a){let g=Ne(a.value)?Ie().read(a.value):U(s).read(a.value);if(g===null)throw new Error(`resolveBlob: blob not found: ::${a.kind}::${a.value}`);return g},hashFn:st,genId:()=>Qe(`${Date.now()}-${Math.random()}`).slice(0,32),kvStorageForRef:a=>se(chunkVQCIOKJV_cjs.b(a).value),requestProcessAccumulated(){if(n?.suppressSpawn||x)return;let a=this,g=p??=chunkVNLMJEIX_cjs.y(e,a,{boardRuntimeStoreRef:R("requestProcessAccumulated")}),v=we({id:"process-accumulated",queueStorage:f("process-accumulated"),handleMessage:async()=>{let b=await g.processAccumulatedEvents({});if(b.status!=="success")throw new Error(b.error||`processAccumulatedEvents returned ${b.status}`)}});x=de(v).catch(b=>{n?.onWarn?.(`[process-accumulated] in-process queue drain failed: ${b instanceof Error?b.message:String(b)}`);}).finally(()=>{x=null,f("process-accumulated").peekActive().length>0&&a.requestProcessAccumulated?.();});},publishBoardChangeNotifications(a){if(!n?.notifyChannel||a.length===0)return;let g=a.map(v=>({id:ue(),ts:new Date().toISOString(),boardRef:chunkVQCIOKJV_cjs.a(e),notification:v}));Ue(n.notifyChannel,g,n.onWarn);},onWarn:n?.onWarn},d}function an(e,t,r){let{cliDir:o,opts:n}=fr(t,r),s,u=()=>(s||(s=ct(o)),s),p=pr(e,o,n),x=Ae({resolveCliDir:u,...n?.resolveRef?{resolveRef:n.resolveRef}:{}});return {...p,invokeExecutor:x.invokeExecutor,validateSchema(c){let l=chunkQEHKMLHA_cjs.d(c);return {ok:l.errors.length===0,errors:l.errors}},absoluteBlob:Ie()}}function cn(e,t={}){let r=t.chatsSubdir??"chats",o=t.kvSubdir??".kv",n=o?[o,"chat"]:["chat"],s=r&&!at(e,r)?C(e,r):e,u=se(C(e,...n));return chunkMCPADH33_cjs.a(p=>{let c=`${String(p).replace(/[^a-zA-Z0-9_-]/g,"_")}.jsonl`,l=C(s,c);return me(l)},u)}function gr(e){return chunkMCPADH33_cjs.a(t=>{let o=`${String(t).replace(/[^a-zA-Z0-9_-]/g,"_")}.jsonl`;return me(C(e,"journal",o))},se(C(e,"kv")))}function un(e,t={}){let r=t.filesSubdir??"files",o=r&&!at(e,r)?C(e,r):e;return chunkNBJTYAYN_cjs.a(U(o))}function dn(e){try{let t=JSON.parse(Buffer.from(e,"base64url").toString());return typeof t.br=="string"?t.br:null}catch{return null}}Object.defineProperty(exports,"createChatStorage",{enumerable:true,get:function(){return chunkMCPADH33_cjs.a}});Object.defineProperty(exports,"createInMemoryChatStorage",{enumerable:true,get:function(){return chunkMCPADH33_cjs.c}});Object.defineProperty(exports,"createArtifactsStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.a}});Object.defineProperty(exports,"createCardFileMetadataStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.c}});Object.defineProperty(exports,"createFileArtifactsStore",{enumerable:true,get:function(){return chunkNBJTYAYN_cjs.b}});Object.defineProperty(exports,"createBoardWorkerStore",{enumerable:true,get:function(){return chunkGPCMBPLK_cjs.a}});Object.defineProperty(exports,"createQueueLaneRegistry",{enumerable:true,get:function(){return chunkGPCMBPLK_cjs.b}});Object.defineProperty(exports,"BOARD_GRAPH_KEY",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.n}});Object.defineProperty(exports,"EMPTY_CONFIG",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.u}});Object.defineProperty(exports,"SNAPSHOT_SCHEMA_VERSION_V1",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.m}});Object.defineProperty(exports,"createBoardLiveCardsNonCorePublic",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.z}});Object.defineProperty(exports,"createBoardLiveCardsPublic",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.y}});Object.defineProperty(exports,"createCardStore",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.l}});Object.defineProperty(exports,"createHttpBoardCallbackTransport",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.e}});Object.defineProperty(exports,"createInProcessBoardCallbackTransport",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.f}});Object.defineProperty(exports,"createLocalNodeBoardCallbackTransport",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.g}});Object.defineProperty(exports,"executionRefFromScriptPath",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.a}});Object.defineProperty(exports,"parseExecutionRef",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.c}});Object.defineProperty(exports,"serializeExecutionRef",{enumerable:true,get:function(){return chunk7JVHYHT2_cjs.b}});Object.defineProperty(exports,"parseRef",{enumerable:true,get:function(){return chunkVQCIOKJV_cjs.b}});Object.defineProperty(exports,"serializeRef",{enumerable:true,get:function(){return chunkVQCIOKJV_cjs.a}});Object.defineProperty(exports,"createBoardLiveCardsMcp",{enumerable:true,get:function(){return chunkGHUW6P4G_cjs.a}});Object.defineProperty(exports,"createCardStorePublic",{enumerable:true,get:function(){return chunk5XLFPPTY_cjs.a}});Object.defineProperty(exports,"createQueueStoragePublic",{enumerable:true,get:function(){return chunkSDJ3747Q_cjs.a}});Object.defineProperty(exports,"createArtifactsStorePublic",{enumerable:true,get:function(){return chunkP7ZCDICS_cjs.a}});exports.buildLocalBaseSpec=le;exports.createBoardWorkerQueueLane=xe;exports.createExecutionRefInvoker=Ut;exports.createFsBlobStorage=U;exports.createFsBoardChatStorage=cn;exports.createFsBoardFileArtifactsStore=un;exports.createFsBoardNonCorePlatformAdapter=an;exports.createFsBoardPlatformAdapter=pr;exports.createFsChatStorageForRefRoot=gr;exports.createFsQueueStorage=je;exports.createHostedAsyncBoardNonCorePublic=ar;exports.createNodeSpawnInvocationAdapter=sn;exports.createNonCoreExecutorDispatcher=Ae;exports.createQueueStorageLane=we;exports.decodeBoardRefFromToken=dn;exports.drainQueueLaneToIdle=de;exports.evaluateArgsMassaging=ke;exports.invokeExecutionRef=Z;exports.invokeExecutionRefSync=ve;exports.invokeRefSync=zt;exports.registerInProcessExecutionHandler=Dt;exports.resolveWhatToRunValue=L;exports.resolveYamlFlowCliPath=Xe;exports.startQueueLaneRunner=Ye;exports.startQueueLaneRunners=Ot;exports.unregisterInProcessExecutionHandler=Kt;//# sourceMappingURL=board-live-cards-node.cjs.map
12
12
  //# sourceMappingURL=board-live-cards-node.cjs.map
@@ -1,4 +1,4 @@
1
- import {a as a$2}from'./chunk-Y4WK7HE4.js';export{a as createChatStorage,c as createInMemoryChatStorage}from'./chunk-Y4WK7HE4.js';import {a as a$5}from'./chunk-CBRVINMT.js';import {a as a$3}from'./chunk-O5UYCGIN.js';export{a as createArtifactsStore,c as createCardFileMetadataStore,b as createFileArtifactsStore}from'./chunk-O5UYCGIN.js';import {a as a$4}from'./chunk-RKKSVOP2.js';export{a as createBoardWorkerStore,b as createQueueLaneRegistry}from'./chunk-RKKSVOP2.js';import {h}from'./chunk-J4MHQ7JF.js';import {a}from'./chunk-VGDLSS2H.js';import'./chunk-QLB6PKOT.js';import'./chunk-BVQISI6G.js';import {b as b$1}from'./chunk-6MD6FVE3.js';import {g,y}from'./chunk-ZA4FS27N.js';export{n as BOARD_GRAPH_KEY,u as EMPTY_CONFIG,m as SNAPSHOT_SCHEMA_VERSION_V1,z as createBoardLiveCardsNonCorePublic,y as createBoardLiveCardsPublic,l as createCardStore,e as createHttpBoardCallbackTransport,f as createInProcessBoardCallbackTransport,g as createLocalNodeBoardCallbackTransport}from'./chunk-ZA4FS27N.js';export{a as executionRefFromScriptPath,c as parseExecutionRef,b as serializeExecutionRef}from'./chunk-ANKA7HEJ.js';import {a as a$1,b}from'./chunk-44L64VQ2.js';export{b as parseRef,a as serializeRef}from'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';export{a as createBoardLiveCardsMcp}from'./chunk-RWAEV253.js';import {a as a$6}from'./chunk-E46UCDYN.js';import {d}from'./chunk-M53MX233.js';import'./chunk-MNEOJWPS.js';export{a as createCardStorePublic}from'./chunk-7QNEV5S3.js';export{a as createQueueStoragePublic}from'./chunk-BJGK5FNL.js';export{a as createArtifactsStorePublic}from'./chunk-X3LC4LII.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';import {spawn,spawnSync,execFile,execFileSync}from'child_process';import*as i from'fs';import*as qe from'os';import*as w from'path';import*as Le from'net';import {fileURLToPath}from'url';import {randomUUID,createHash}from'crypto';import {createRequire}from'module';import {lockSync}from'proper-lockfile';function C(...e){return w.join(...e)}function Ne(e){return w.isAbsolute(e)}function ue(){return randomUUID()}function Qe(e){return createHash("sha256").update(e).digest("hex")}function Je(e){return w.dirname(fileURLToPath(e))}function Ft(e){if(typeof e=="object"&&e!==null){let{command:r,args:o=[],...n}=e,s=Oe(r,o);return {...n,command:s.command,args:s.args}}let t=De(e);if(t.length===0)throw new Error(`Empty command spec: ${JSON.stringify(e)}`);return Oe(t[0],t.slice(1))}function Oe(e,t){return /^(node|node\.exe)$/i.test(e)?{command:process.execPath,args:t}:/\.m?js$/i.test(e)?{command:process.execPath,args:[e,...t]}:{command:e,args:t}}function De(e){let t=[],r="",o=null;for(let n of e.trim()){if(o){n===o?o=null:r+=n;continue}if(n==='"'||n==="'"){o=n;continue}if(/\s/.test(n)){r&&(t.push(r),r="");continue}r+=n;}if(o)throw new Error(`Unterminated quote in command: ${e}`);return r&&t.push(r),t}function Ke(e){return process.platform==="win32"&&/\.(cmd|bat)$/i.test(e)}function We(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u}=e;return execFileSync(r,o,{shell:Ke(r),timeout:u,encoding:t?.encoding??"utf-8",cwd:n,windowsHide:true,env:s?{...process.env,...s}:void 0,input:t?.input})}function $t(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u=3e4}=e;execFile(r,o,{shell:Ke(r),encoding:"utf8",windowsHide:true,timeout:u,maxBuffer:10*1024*1024,cwd:n,env:s?{...process.env,...s}:void 0},(p,x,c)=>t(p??null,x,c));}function He(e,t,r){let o=w.join(e,"board-live-cards-cli.js");if(i.existsSync(o))return {cmd:process.execPath,args:[o,t,...r]};let n=w.join(e,"board-live-cards-cli.ts"),u=[w.join(e,"..","..","..","node_modules","tsx","dist","cli.mjs"),w.join(e,"..","..","node_modules","tsx","dist","cli.mjs"),w.join(e,"..","..","..","node_modules",".bin","tsx"),w.join(e,"..","..","node_modules",".bin","tsx")].find(x=>i.existsSync(x));return i.existsSync(n)&&u?{cmd:process.execPath,args:[u,n,t,...r]}:{cmd:process.platform==="win32"?"npx.cmd":"npx",args:["tsx",n,t,...r]}}function Ve(e){let t=w.join(e,"board-live-cards-cli.mjs");if(i.existsSync(t))return t;let r=w.join(e,"..","..","..","dev","board-live-cards-cli.js");if(i.existsSync(r))return r;let o=w.join(e,"..","..","dev","board-live-cards-cli.js");if(i.existsSync(o))return o;let n=w.join(e,"board-live-cards-cli.js");if(i.existsSync(n))return n;throw new Error(`resolveBoardCliCallbackTarget: cannot find callback target in ${e} (expected dev/board-live-cards-cli.js wrapper, ${n}, or ${t})`)}function Mt(e){return process.platform==="win32"?`\\\\.\\pipe\\${e}`:w.join(qe.tmpdir(),`${e}.sock`)}var ce=new Map;function Ue(e,t,r){if(t.length===0)return;let o=t.map(p=>JSON.stringify(p)).join(`
1
+ import {a as a$2}from'./chunk-Y4WK7HE4.js';export{a as createChatStorage,c as createInMemoryChatStorage}from'./chunk-Y4WK7HE4.js';import {a as a$5}from'./chunk-2LGCYN35.js';import {a as a$3}from'./chunk-O5UYCGIN.js';export{a as createArtifactsStore,c as createCardFileMetadataStore,b as createFileArtifactsStore}from'./chunk-O5UYCGIN.js';import {a as a$4}from'./chunk-RKKSVOP2.js';export{a as createBoardWorkerStore,b as createQueueLaneRegistry}from'./chunk-RKKSVOP2.js';import {h}from'./chunk-J4MHQ7JF.js';import {a}from'./chunk-VGDLSS2H.js';import'./chunk-QLB6PKOT.js';import'./chunk-5U5NMYGT.js';import {b as b$1}from'./chunk-6MD6FVE3.js';import {g,y}from'./chunk-H5FKNSCO.js';export{n as BOARD_GRAPH_KEY,u as EMPTY_CONFIG,m as SNAPSHOT_SCHEMA_VERSION_V1,z as createBoardLiveCardsNonCorePublic,y as createBoardLiveCardsPublic,l as createCardStore,e as createHttpBoardCallbackTransport,f as createInProcessBoardCallbackTransport,g as createLocalNodeBoardCallbackTransport}from'./chunk-H5FKNSCO.js';export{a as executionRefFromScriptPath,c as parseExecutionRef,b as serializeExecutionRef}from'./chunk-ANKA7HEJ.js';import {a as a$1,b}from'./chunk-44L64VQ2.js';export{b as parseRef,a as serializeRef}from'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';export{a as createBoardLiveCardsMcp}from'./chunk-6M3RIGUH.js';import {a as a$6}from'./chunk-ATOQP3BD.js';import {d}from'./chunk-YT76JNKE.js';import'./chunk-MNEOJWPS.js';export{a as createCardStorePublic}from'./chunk-7QNEV5S3.js';export{a as createQueueStoragePublic}from'./chunk-BJGK5FNL.js';export{a as createArtifactsStorePublic}from'./chunk-X3LC4LII.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';import {spawn,spawnSync,execFile,execFileSync}from'child_process';import*as i from'fs';import*as qe from'os';import*as w from'path';import*as Le from'net';import {fileURLToPath}from'url';import {randomUUID,createHash}from'crypto';import {createRequire}from'module';import {lockSync}from'proper-lockfile';function C(...e){return w.join(...e)}function Ne(e){return w.isAbsolute(e)}function ue(){return randomUUID()}function Qe(e){return createHash("sha256").update(e).digest("hex")}function Je(e){return w.dirname(fileURLToPath(e))}function Ft(e){if(typeof e=="object"&&e!==null){let{command:r,args:o=[],...n}=e,s=Oe(r,o);return {...n,command:s.command,args:s.args}}let t=De(e);if(t.length===0)throw new Error(`Empty command spec: ${JSON.stringify(e)}`);return Oe(t[0],t.slice(1))}function Oe(e,t){return /^(node|node\.exe)$/i.test(e)?{command:process.execPath,args:t}:/\.m?js$/i.test(e)?{command:process.execPath,args:[e,...t]}:{command:e,args:t}}function De(e){let t=[],r="",o=null;for(let n of e.trim()){if(o){n===o?o=null:r+=n;continue}if(n==='"'||n==="'"){o=n;continue}if(/\s/.test(n)){r&&(t.push(r),r="");continue}r+=n;}if(o)throw new Error(`Unterminated quote in command: ${e}`);return r&&t.push(r),t}function Ke(e){return process.platform==="win32"&&/\.(cmd|bat)$/i.test(e)}function We(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u}=e;return execFileSync(r,o,{shell:Ke(r),timeout:u,encoding:t?.encoding??"utf-8",cwd:n,windowsHide:true,env:s?{...process.env,...s}:void 0,input:t?.input})}function $t(e,t){let{command:r,args:o=[],cwd:n,env:s,timeoutMs:u=3e4}=e;execFile(r,o,{shell:Ke(r),encoding:"utf8",windowsHide:true,timeout:u,maxBuffer:10*1024*1024,cwd:n,env:s?{...process.env,...s}:void 0},(p,x,c)=>t(p??null,x,c));}function He(e,t,r){let o=w.join(e,"board-live-cards-cli.js");if(i.existsSync(o))return {cmd:process.execPath,args:[o,t,...r]};let n=w.join(e,"board-live-cards-cli.ts"),u=[w.join(e,"..","..","..","node_modules","tsx","dist","cli.mjs"),w.join(e,"..","..","node_modules","tsx","dist","cli.mjs"),w.join(e,"..","..","..","node_modules",".bin","tsx"),w.join(e,"..","..","node_modules",".bin","tsx")].find(x=>i.existsSync(x));return i.existsSync(n)&&u?{cmd:process.execPath,args:[u,n,t,...r]}:{cmd:process.platform==="win32"?"npx.cmd":"npx",args:["tsx",n,t,...r]}}function Ve(e){let t=w.join(e,"board-live-cards-cli.mjs");if(i.existsSync(t))return t;let r=w.join(e,"..","..","..","dev","board-live-cards-cli.js");if(i.existsSync(r))return r;let o=w.join(e,"..","..","dev","board-live-cards-cli.js");if(i.existsSync(o))return o;let n=w.join(e,"board-live-cards-cli.js");if(i.existsSync(n))return n;throw new Error(`resolveBoardCliCallbackTarget: cannot find callback target in ${e} (expected dev/board-live-cards-cli.js wrapper, ${n}, or ${t})`)}function Mt(e){return process.platform==="win32"?`\\\\.\\pipe\\${e}`:w.join(qe.tmpdir(),`${e}.sock`)}var ce=new Map;function Ue(e,t,r){if(t.length===0)return;let o=t.map(p=>JSON.stringify(p)).join(`
2
2
  `)+`
3
3
  `,n=ce.get(e);if(n&&!n.socket.destroyed){n.ready?n.socket.write(o):n.queue.push(o);return}let s=Mt(e),u=Le.createConnection(s);n={socket:u,ready:false,queue:[o]},ce.set(e,n),u.on("connect",()=>{n.ready=true;for(let p of n.queue)u.write(p);n.queue.length=0;}),u.on("error",p=>{r?.(`[named-pipe publish] ${s}: ${p instanceof Error?p.message:String(p)}`),ce.delete(e);}),u.on("close",()=>{ce.delete(e);});}function ze(){return {executeSync(e,t,r){return We({command:e,args:t,cwd:r?.cwd,timeoutMs:r?.timeout,env:r?.env},{encoding:r?.encoding,input:r?.input})},executeAsync(e,t,r){$t({command:e,args:t},r);},resolveInvocation(e,t){let r=Ft({command:e,args:t});return {cmd:r.command,args:r.args??[]}},splitCommand:De}}function xe(e){return {id:e.id??"board-worker",pollIntervalMs:e.pollIntervalMs,visibilityMs:e.visibilityMs,concurrency:e.concurrency,maxAttempts:e.maxAttempts,async lease(t){return e.workerStore.leaseRequests(t).map(r=>({id:r.messageId,attempt:r.attempt,message:r.request,ack:()=>e.workerStore.ackRequest(r.messageId,r.leaseToken),nack:o=>e.workerStore.nackRequest(r.messageId,r.leaseToken,o)}))},async handle(t){await e.handleRequest(t.args,t);},onError:e.onError}}function we(e){return {id:e.id,pollIntervalMs:e.pollIntervalMs,visibilityMs:e.visibilityMs,concurrency:e.concurrency,maxAttempts:e.maxAttempts,async lease(t){return e.queueStorage.lease(t).map(r=>({id:r.id,attempt:r.attempt,message:r.body,ack:()=>e.queueStorage.ack(r.id,r.leaseToken),nack:o=>e.queueStorage.nack(r.id,r.leaseToken,o)}))},handle:e.handleMessage,onError:e.onError}}async function Ge(e,t){try{await e.handle(t.message,t),await t.ack();}catch(r){let o=t.attempt>=Math.max(1,Math.floor(e.maxAttempts??5));await t.nack({dead:o,reason:r instanceof Error?r.message:String(r)}),e.onError?.(r,t);}}function Ye(e){let t=Math.max(1,Math.floor(e.pollIntervalMs??250)),r=Math.max(1,Math.floor(e.visibilityMs??6e4)),o=Math.max(1,Math.floor(e.concurrency??1)),n=false,s=false;async function u(){if(!(n||s)){s=true;try{let x=await e.lease({max:o,visibilityMs:r});for(let c of x)await Ge(e,c);}finally{s=false;}}}let p=setInterval(()=>{u();},t);return typeof p.unref=="function"&&p.unref(),u(),()=>{n=true,clearInterval(p);}}async function _t(e){let t=Math.max(1,Math.floor(e.visibilityMs??6e4)),r=Math.max(1,Math.floor(e.concurrency??1)),o=await e.lease({max:r,visibilityMs:t});for(let n of o)await Ge(e,n);return o.length}async function de(e,t){let r=Math.max(1,Math.floor(t?.maxPasses??256)),o=0;for(let n=0;n<r;n+=1){let s=await _t(e);if(o+=s,s<=0)return o}throw new Error(`drainQueueLaneToIdle exceeded ${r} passes for lane "${e.id}"`)}function Ot(e){let r=(Array.isArray(e)?e:e.lanes).map(o=>Ye(o));return ()=>{for(let o of r)o();}}var Lt=createRequire(import.meta.url);function Nt(e){return typeof e=="object"?e:b(e)}function Xe(e){let t=w.basename(String(e||"").trim());if(!t)throw new Error(`resolveYamlFlowCliPath: expected non-empty cli file name, got ${JSON.stringify(e)}`);let r=w.dirname(Lt.resolve("yaml-flow/package.json")),o=t.replace(/\.[^.]+$/,""),n=w.join(r,"cli","bundled",`${o}.mjs`);if(i.existsSync(n))return n;let s=w.join(r,"cli","node",t);if(i.existsSync(s))return s;throw new Error(`resolveYamlFlowCliPath: could not find ${t} under cli/bundled or cli/node in ${r}`)}function L(e){let t=Nt(e);return t.kind==="yaml-flow-cli"?Xe(t.value):t.value}function Qt(e,t){let r=L(e);switch(r){case "source-cli-task-executor":{let o=w.join(t,"source-cli-task-executor.js");if(i.existsSync(o))return {command:process.execPath,args:[o]};let n=w.join(t,"source-cli-task-executor.ts"),s=w.join(t,"..","..","node_modules","tsx","dist","cli.mjs"),u=w.join(t,"..","..","node_modules",".bin","tsx"),p=i.existsSync(s)?s:u;return i.existsSync(n)&&i.existsSync(p)?{command:process.execPath,args:[p,n]}:{command:process.execPath,args:[o]}}case "board-live-cards":{let{cmd:o,args:n}=He(t,"_",[]);return {command:o,args:n}}default:throw new Error(`resolveBuiltIn: unknown built-in name "${r}". Supported: source-cli-task-executor, board-live-cards`)}}function Jt(e,t){if(e.howToRun==="built-in"){let{command:o,args:n}=Qt(e.whatToRun,t);return {command:o,baseArgs:n}}let r=(typeof e.whatToRun=="object",L(e.whatToRun));switch(e.howToRun){case "local-node":return {command:process.execPath,baseArgs:[r]};case "local-python":return {command:process.platform==="win32"?"python":"python3",baseArgs:[r]};case "local-process":return {command:r,baseArgs:[]};default:throw new Error(`resolveBaseInvocation: howToRun "${e.howToRun}" is not a local transport`)}}function le(e,t){return Jt(e,t)}var be=new Map;function Dt(e,t){let r=String(e||"").trim();if(!r)throw new Error("registerInProcessExecutionHandler: key is required");be.set(r,t);}function Kt(e){let t=String(e||"").trim();t&&be.delete(t);}function et(e){let t=e.trim();if(!t)throw new Error("empty stdout");try{return JSON.parse(t)}catch{let r=t.split(/\r?\n/).filter(Boolean),o=r[r.length-1];return JSON.parse(o)}}function tt(e,t){return {...t,whatToRun:L(e.whatToRun),...e.extra?{extra:e.extra}:{}}}function ke(e,t,r="invokeExecutionRef"){return a(e,t,r)}function rt(e,t){if(e&&typeof e=="object"&&!Array.isArray(e)&&typeof e.result=="string"&&e.data&&typeof e.data=="object"&&!Array.isArray(e.data))return {...e,...t||{}};if(e&&typeof e=="object"&&!Array.isArray(e)&&typeof e.status=="string"){let o=e,n=o.status==="success"?"success":o.status==="fail"?"failure":o.status,s=o.data&&typeof o.data=="object"&&!Array.isArray(o.data)?o.data:o.data===void 0?{}:{stdout:o.data};return {result:n,data:s,...typeof o.error=="string"?{error:o.error}:{},...t||{}}}return {result:"success",data:e&&typeof e=="object"&&!Array.isArray(e)?e:{stdout:e},...t||{}}}function q(e){return {result:"failure",data:{error:e}}}function V(e,t,r){let o=r?.label??"invokeExecutionRefSync",n=r?.cliDir??r?.cwd??process.cwd(),s;try{s=ke(e.argsMassaging,tt(e,t),o);}catch(h){let R=h instanceof Error?h.message:String(h);return q(R)}let u;try{u=le(e,n);}catch(h){let R=h instanceof Error?h.message:String(h);return q(`[${o}] ref resolution failed: ${R}`)}let p=[...u.baseArgs,...s.cmdArgs??[]],x=JSON.stringify(s.stdin??t),c=ze(),l;try{l=c.executeSync(u.command,p,{timeout:r?.timeoutMs??3e4,encoding:"utf-8",cwd:r?.cwd,input:x});}catch(h){let R=h,y=(R.stderr?String(R.stderr):"").trim(),d=typeof R.status=="number"?R.status:"unknown",f=y||R.message;return q(`[${o}] ref exited with status ${d}${f?`: ${f}`:""}`)}try{return rt(et(l))}catch{return {result:"success",data:{stdout:l.trim()}}}}async function Ze(e,t,r){let o=r?.label??"invokeExecutionRef",n;try{n=ke(e.argsMassaging,tt(e,t),o);}catch(h){let R=h instanceof Error?h.message:String(h);return q(R)}let s=L(e.whatToRun),u=n.headers?{"Content-Type":"application/json",...n.headers}:{"Content-Type":"application/json"},p=n.url??s,x;if(e.howToRun==="http:get"){let h=n.body&&typeof n.body=="object"&&!Array.isArray(n.body)?n.body:t,R=new URLSearchParams(Object.entries(h).filter(([,y])=>y!=null).map(([y,d])=>[y,String(d)]));R.size>0&&(p=`${p}${p.includes("?")?"&":"?"}${R.toString()}`);}else x=JSON.stringify(n.body??t);let c={method:e.howToRun==="http:get"?"GET":"POST",headers:u,body:x},l=0;for(;;)try{let h=await fetch(p,c);if(!h.ok){let f=await h.text().catch(()=>"");return q(`[${o}] HTTP ${h.status}${f?`: ${f}`:""}`)}let R={};h.headers.forEach((f,m)=>{R[m]=f;});let y=new Uint8Array(await h.arrayBuffer());if(y.byteLength===0)return {result:"success",data:{},headers:R};let d=new TextDecoder().decode(y);try{return rt(et(d),{headers:R})}catch{return {result:"success",data:{stdout:d},headers:R}}}catch(h){let R=h?.cause,y=R&&typeof R=="object"&&"code"in R?String(R.code||""):"";if((y==="ECONNRESET"||y==="UND_ERR_SOCKET")&&l===0){l+=1;continue}let f=h instanceof Error?h.message:String(h),m=R instanceof Error?`${R.name}: ${R.message}${y?` [${y}]`:""}`:R?String(R):"",S=n.url??s??"",a=`${f}${m?` (cause: ${m})`:""}${S?` url=${S}`:""}`;return q(`[${o}] ${a}`)}}async function Wt(e,t,r){let o=r?.label??"invokeExecutionRef",n=L(e.whatToRun).trim();if(!n)return q(`[${o}] in-process-loop requires a non-empty handler key`);let s=be.get(n);if(!s)return q(`[${o}] no in-process handler registered for: ${n}`);try{return await s(e,t,r)}catch(u){let p=u instanceof Error?u.message:String(u);return q(`[${o}] ${p}`)}}var Ht={"local-node":async(e,t,r)=>V(e,t,r),"local-python":async(e,t,r)=>V(e,t,r),"local-process":async(e,t,r)=>V(e,t,r),"built-in":async(e,t,r)=>V(e,t,r),"http:post":Ze,"http:get":Ze,"in-process-loop":Wt},Vt={"local-node":V,"local-python":V,"local-process":V,"built-in":V};async function Z(e,t,r){let o=r?.transports?.[e.howToRun]??Ht[e.howToRun];return o?o(e,t,r):q(`[${r?.label??"invokeExecutionRef"}] unsupported howToRun: ${e.howToRun}`)}function ve(e,t,r){let o=r?.syncTransports?.[e.howToRun]??Vt[e.howToRun];return o?o(e,t,r):q(`[${r?.label??"invokeExecutionRefSync"}] unsupported sync howToRun: ${e.howToRun}`)}function Ut(e){return {invoke(t,r){return Z(t,r,e)},invokeSync(t,r){return ve(t,r,e)}}}function zt(e,t,r){return ve(e,t,r)}function Ae(e={}){let t=e.resolveRef??(r=>r);return {...e.executorTimeouts?{executorTimeouts:e.executorTimeouts}:{},async invokeExecutor(r,o,n){let s=t(r);if(s.howToRun==="queue-storage")throw new Error("queue-storage does not support inline executor request/response");if(s.howToRun==="http:post"||s.howToRun==="in-process-loop"){let l=await h(s,{subcommand:o,...n?.input!==void 0?{input:n.input}:{}});return typeof l=="string"?l:l&&typeof l=="object"&&!Array.isArray(l)&&typeof l.stdout=="string"?String(l.stdout):JSON.stringify(l??{})}if(s.howToRun==="http:get"){let l=await Z(s,{subcommand:o,...n?.input!==void 0?{input:n.input}:{},...s.extra?{extra:s.extra}:{}},{cwd:process.cwd(),timeoutMs:n?.timeout??3e4,label:`invokeExecutor:${o}`});if(l.result!=="success"){let h=typeof l.data?.error=="string"?l.data.error:l.error;throw new Error(h||`executor request failed: ${l.result}`)}return typeof l.data?.stdout=="string"?l.data.stdout:JSON.stringify(l.data??{})}if(!e.resolveCliDir)throw new Error(`createNonCoreExecutorDispatcher: ref.howToRun="${s.howToRun}" requires opts.resolveCliDir`);let{command:u,baseArgs:p}=le(s,e.resolveCliDir()),x=s.extra?["--extra",Buffer.from(JSON.stringify(s.extra)).toString("base64")]:[],c=[...p,o,...x];return await new Promise((l,h)=>{let R=spawn(u,c,{cwd:process.cwd(),stdio:"pipe",windowsHide:true,shell:process.platform==="win32"&&/\.(cmd|bat)$/i.test(u)}),y=[],d=[],f=false,m=null,S=g=>{f||(f=true,m&&clearTimeout(m),h(g));},a=g=>{f||(f=true,m&&clearTimeout(m),l(g));};R.stdout.on("data",g=>{y.push(Buffer.from(g));}),R.stderr.on("data",g=>{d.push(Buffer.from(g));}),R.on("error",g=>{let v=g;v.stdout=Buffer.concat(y).toString("utf-8"),v.stderr=Buffer.concat(d).toString("utf-8"),S(v);}),R.on("close",g=>{let v=Buffer.concat(y).toString("utf-8"),b=Buffer.concat(d).toString("utf-8");if(g===0){a(v);return}let k=new Error(b.trim()||`executor exited with status ${g}`);k.stdout=v,k.stderr=b,S(k);}),n?.timeout&&n.timeout>0&&(m=setTimeout(()=>{R.kill();let g=new Error(`executor timed out after ${n.timeout}ms`);g.stdout=Buffer.concat(y).toString("utf-8"),g.stderr=Buffer.concat(d).toString("utf-8"),S(g);},n.timeout)),n?.input!==void 0?R.stdin.end(n.input):R.stdin.end();})}}}function B(e,t){if(process.platform!=="win32"){i.renameSync(e,t);return}let r=[10,20,40,80,160];for(let o=0;o<=r.length;o++)try{i.renameSync(e,t);return}catch(n){let s=n.code;if((s==="EPERM"||s==="EBUSY")&&o<r.length){Atomics.wait(new Int32Array(new SharedArrayBuffer(4)),0,0,r[o]);continue}throw n}}function U(e){function t(n){return w.join(e,...n.split("/"))}function r(n){return w.relative(e,n).replace(/\\/g,"/")}function o(n,s){if(i.existsSync(n))for(let u of i.readdirSync(n,{withFileTypes:true})){let p=w.join(n,u.name);if(u.isDirectory()){o(p,s);continue}u.isFile()&&s.push(r(p));}}return {read(n){let s=t(n);if(!i.existsSync(s))return null;try{return i.readFileSync(s,"utf-8")}catch{return null}},write(n,s){let u=t(n),p=`${u}.${process.pid}.${randomUUID()}.tmp`;i.mkdirSync(w.dirname(u),{recursive:true}),i.writeFileSync(p,s,"utf-8"),B(p,u);},exists(n){return i.existsSync(t(n))},remove(n){let s=t(n);try{i.existsSync(s)&&i.unlinkSync(s);}catch{}},readBytes(n){let s=t(n);if(!i.existsSync(s))return null;try{return new Uint8Array(i.readFileSync(s))}catch{return null}},writeBytes(n,s){let u=t(n),p=`${u}.${process.pid}.${randomUUID()}.tmp`;i.mkdirSync(w.dirname(u),{recursive:true}),i.writeFileSync(p,Buffer.from(s)),B(p,u);},listKeys(n){let s=[];o(e,s);let u=s.sort();return n?u.filter(p=>p.startsWith(n)):u},stat(n){let s=t(n);if(!i.existsSync(s))return null;try{let u=i.statSync(s);return {key:n,size:Number(u.size||0),updatedAt:new Date(u.mtimeMs).toISOString()}}catch{return null}},keyRef(n){return {kind:"fs-path",value:t(n)}},renameKey(n,s){let u=t(n);if(!i.existsSync(u))return false;let p=t(s);return i.mkdirSync(w.dirname(p),{recursive:true}),B(u,p),true}}}function Ie(){return {read(e){if(!i.existsSync(e))return null;try{return i.readFileSync(e,"utf-8")}catch{return null}},write(e,t){let r=`${e}.${process.pid}.${randomUUID()}.tmp`;i.mkdirSync(w.dirname(e),{recursive:true}),i.writeFileSync(r,t,"utf-8"),B(r,e);},exists(e){return i.existsSync(e)},remove(e){try{i.existsSync(e)&&i.unlinkSync(e);}catch{}},readBytes(e){if(!i.existsSync(e))return null;try{return new Uint8Array(i.readFileSync(e))}catch{return null}},writeBytes(e,t){let r=`${e}.${process.pid}.${randomUUID()}.tmp`;i.mkdirSync(w.dirname(e),{recursive:true}),i.writeFileSync(r,Buffer.from(t)),B(r,e);},stat(e){if(!i.existsSync(e))return null;try{let t=i.statSync(e);return {key:e,size:Number(t.size||0),updatedAt:new Date(t.mtimeMs).toISOString()}}catch{return null}},listKeys(e){return []},renameKey(e,t){return i.existsSync(e)?(i.mkdirSync(w.dirname(t),{recursive:true}),B(e,t),true):false}}}function D(e,t){let r=`${e}.${process.pid}.${randomUUID()}.tmp`;i.mkdirSync(w.dirname(e),{recursive:true}),i.writeFileSync(r,JSON.stringify(t,null,2),"utf-8"),B(r,e);}function N(e){if(!i.existsSync(e))return null;try{return JSON.parse(i.readFileSync(e,"utf-8"))}catch{return null}}function X(e){return i.existsSync(e)?i.readdirSync(e).filter(t=>t.endsWith(".json")).sort().map(t=>w.join(e,t)):[]}function ee(e){return {id:e.id,body:e.body,enqueuedAt:e.enqueuedAt,attempt:e.attempt}}function Xt(e){return {...ee(e),leaseToken:String(e.leaseToken||""),leaseExpiresAt:String(e.leaseExpiresAt||"")}}function er(e){return {...ee(e),reason:e.reason}}function je(e){let t=w.join(e,"active"),r=w.join(e,"leased"),o=w.join(e,"done"),n=w.join(e,"dead"),s=w.join(e,"staged");for(let d of [t,r,o,n,s])i.mkdirSync(d,{recursive:true});let u=0;function p(d){let f=d.replace(/[:.]/g,"-"),m=String(u++).padStart(6,"0");return `${f}-${m}`}function x(d){let f=d.activeOrderKey||p(String(d.enqueuedAt||new Date().toISOString()));return w.join(t,`${f}-${d.id}.json`)}function c(d){return w.join(r,`${d}.json`)}function l(d){return w.join(o,`${d}.json`)}function h(d){return w.join(n,`${d}.json`)}function R(d){return w.join(s,`${d}.json`)}function y(){let d=Date.now();for(let f of X(r)){let m=N(f);if(!m?.leaseExpiresAt)continue;let S=Date.parse(m.leaseExpiresAt);if(Number.isNaN(S)||S>d)continue;let a={id:m.id,body:m.body,enqueuedAt:m.enqueuedAt,attempt:m.attempt,activeOrderKey:m.activeOrderKey};D(x(a),a);try{i.unlinkSync(f);}catch{}}}return {enqueue(d){let f={id:randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0};return f.activeOrderKey=p(f.enqueuedAt),D(x(f),f),ee(f)},enqueueMany(d){return d.map(f=>this.enqueue(f))},enqueueIfAbsent(d,f){y();for(let S of [t,r,s])for(let a of X(S))if(N(a)?.dedupKey===f)return null;let m={id:randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0,dedupKey:f};return m.activeOrderKey=p(m.enqueuedAt),D(x(m),m),ee(m)},lease(d){y();let f=Math.max(1,Math.floor(d?.max??1)),m=Math.max(1,Math.floor(d?.visibilityMs??6e4)),S=[];for(let a of X(t)){if(S.length>=f)break;let g=N(a);if(!g)continue;let v=c(g.id);try{B(a,v);}catch{continue}let b={...g,attempt:(Number(g.attempt)||0)+1,leaseToken:randomUUID(),leaseExpiresAt:new Date(Date.now()+m).toISOString()};D(v,b),S.push(Xt(b));}return S},ack(d,f){let m=c(d),S=N(m);if(!S||S.leaseToken!==f)return false;try{B(m,l(d));}catch{return false}return true},nack(d,f,m){let S=c(d),a=N(S);if(!a||a.leaseToken!==f)return false;let g={id:a.id,body:a.body,enqueuedAt:a.enqueuedAt,attempt:a.attempt,activeOrderKey:a.activeOrderKey};m?.dead?(g.reason=m.reason,D(h(d),g)):D(x(g),g);try{i.unlinkSync(S);}catch{}return true},peekActive(d){return y(),X(t).map(f=>N(f)).filter(f=>!!f).map(ee)},peekDeadLetter(d){return X(n).map(f=>N(f)).filter(f=>!!f).map(er)},stage(d,f){let m=f?.dedupKey;if(m){y();for(let a of [t,r,s])for(let g of X(a))if(N(g)?.dedupKey===m)return null}let S={id:randomUUID(),body:d,enqueuedAt:new Date().toISOString(),attempt:0,...m?{dedupKey:m}:{}};return D(R(S.id),S),ee(S)},commitStaged(d){let f=R(d),m=N(f);if(!m)return false;let S=new Date().toISOString(),a={...m,attempt:0,enqueuedAt:S,activeOrderKey:p(S)};D(x(a),a);try{i.unlinkSync(f);}catch{}return true},discardStaged(d,f){let m=R(d),S=N(m);if(!S)return false;let a={id:S.id,body:S.body,enqueuedAt:S.enqueuedAt,attempt:S.attempt,reason:f};D(h(d),a);try{i.unlinkSync(m);}catch{}return true},peekStaged(d){return X(s).map(f=>N(f)).filter(f=>!!f).map(ee)}}}var Ee="__scratch-marker",Te="__scratch-config.json",tr=1440*60*1e3,rr=720*60*1e3,nr=500;function nt(e,t){if(!e)return t;let r=e.replace(/[^A-Za-z0-9._-]/g,"_");return r.length>0?r:t}function oe(e){i.mkdirSync(e,{recursive:true});let t=w.join(e,Ee),r=w.join(e,Te),o=!i.existsSync(t);if(o)try{i.writeFileSync(t,`scratch-store
4
4
  ${new Date().toISOString()}
@@ -1,2 +1,2 @@
1
- 'use strict';var chunkYXKWIPQM_cjs=require('./chunk-YXKWIPQM.cjs');require('./chunk-7JVHYHT2.cjs'),require('./chunk-VQCIOKJV.cjs'),require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs'),require('./chunk-UG55PF75.cjs'),require('./chunk-JHXRGPL7.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-5XLFPPTY.cjs'),require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"BOARD_GRAPH_KEY",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.n}});Object.defineProperty(exports,"EMPTY_CONFIG",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.u}});Object.defineProperty(exports,"SNAPSHOT_SCHEMA_VERSION_V1",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.m}});Object.defineProperty(exports,"createBoardLiveCardsNonCorePublic",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.z}});Object.defineProperty(exports,"createBoardLiveCardsPublic",{enumerable:true,get:function(){return chunkYXKWIPQM_cjs.y}});//# sourceMappingURL=board-live-cards-public.cjs.map
1
+ 'use strict';var chunkVNLMJEIX_cjs=require('./chunk-VNLMJEIX.cjs');require('./chunk-7JVHYHT2.cjs'),require('./chunk-VQCIOKJV.cjs'),require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs'),require('./chunk-QBEQL4TL.cjs'),require('./chunk-QEHKMLHA.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-5XLFPPTY.cjs'),require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"BOARD_GRAPH_KEY",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.n}});Object.defineProperty(exports,"EMPTY_CONFIG",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.u}});Object.defineProperty(exports,"SNAPSHOT_SCHEMA_VERSION_V1",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.m}});Object.defineProperty(exports,"createBoardLiveCardsNonCorePublic",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.z}});Object.defineProperty(exports,"createBoardLiveCardsPublic",{enumerable:true,get:function(){return chunkVNLMJEIX_cjs.y}});//# sourceMappingURL=board-live-cards-public.cjs.map
2
2
  //# sourceMappingURL=board-live-cards-public.cjs.map
@@ -1,2 +1,2 @@
1
- export{n as BOARD_GRAPH_KEY,u as EMPTY_CONFIG,m as SNAPSHOT_SCHEMA_VERSION_V1,z as createBoardLiveCardsNonCorePublic,y as createBoardLiveCardsPublic}from'./chunk-ZA4FS27N.js';import'./chunk-ANKA7HEJ.js';import'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';import'./chunk-E46UCDYN.js';import'./chunk-M53MX233.js';import'./chunk-MNEOJWPS.js';import'./chunk-7QNEV5S3.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-public.js.map
1
+ export{n as BOARD_GRAPH_KEY,u as EMPTY_CONFIG,m as SNAPSHOT_SCHEMA_VERSION_V1,z as createBoardLiveCardsNonCorePublic,y as createBoardLiveCardsPublic}from'./chunk-H5FKNSCO.js';import'./chunk-ANKA7HEJ.js';import'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';import'./chunk-ATOQP3BD.js';import'./chunk-YT76JNKE.js';import'./chunk-MNEOJWPS.js';import'./chunk-7QNEV5S3.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-public.js.map
2
2
  //# sourceMappingURL=board-live-cards-public.js.map
@@ -1,2 +1,2 @@
1
- 'use strict';var chunkWYKCHXBZ_cjs=require('./chunk-WYKCHXBZ.cjs');require('./chunk-LFVMX23W.cjs'),require('./chunk-NM6O35RY.cjs'),require('./chunk-NBJTYAYN.cjs'),require('./chunk-KSKPS6OO.cjs');var chunkBQJVCCFU_cjs=require('./chunk-BQJVCCFU.cjs');require('./chunk-BQUQTOPB.cjs'),require('./chunk-GPCMBPLK.cjs'),require('./chunk-7FGPOGRV.cjs'),require('./chunk-LPXVVMQT.cjs'),require('./chunk-272IYUKT.cjs'),require('./chunk-N5RUH4NG.cjs'),require('./chunk-WRMOGPRG.cjs'),require('./chunk-YXKWIPQM.cjs'),require('./chunk-7JVHYHT2.cjs'),require('./chunk-VQCIOKJV.cjs'),require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs'),require('./chunk-IRGTOCEU.cjs'),require('./chunk-UG55PF75.cjs'),require('./chunk-JHXRGPL7.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-5XLFPPTY.cjs'),require('./chunk-SDJ3747Q.cjs'),require('./chunk-OF4FPYNI.cjs'),require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"createMultiBoardServerRuntime",{enumerable:true,get:function(){return chunkWYKCHXBZ_cjs.b}});Object.defineProperty(exports,"createSingleBoardServerRuntime",{enumerable:true,get:function(){return chunkWYKCHXBZ_cjs.a}});Object.defineProperty(exports,"createHostedBoardQueueLaneRegistry",{enumerable:true,get:function(){return chunkBQJVCCFU_cjs.a}});//# sourceMappingURL=board-live-cards-server-runtime.cjs.map
1
+ 'use strict';var chunkU6JMXOER_cjs=require('./chunk-U6JMXOER.cjs');require('./chunk-LFVMX23W.cjs'),require('./chunk-NM6O35RY.cjs'),require('./chunk-NBJTYAYN.cjs'),require('./chunk-NMOUBZXX.cjs');var chunkBQJVCCFU_cjs=require('./chunk-BQJVCCFU.cjs');require('./chunk-BQUQTOPB.cjs'),require('./chunk-GPCMBPLK.cjs'),require('./chunk-7FGPOGRV.cjs'),require('./chunk-LPXVVMQT.cjs'),require('./chunk-272IYUKT.cjs'),require('./chunk-X5CZE2L7.cjs'),require('./chunk-WRMOGPRG.cjs'),require('./chunk-VNLMJEIX.cjs'),require('./chunk-7JVHYHT2.cjs'),require('./chunk-VQCIOKJV.cjs'),require('./chunk-G4XXRHL2.cjs'),require('./chunk-LODXIALE.cjs'),require('./chunk-GHUW6P4G.cjs'),require('./chunk-QBEQL4TL.cjs'),require('./chunk-QEHKMLHA.cjs'),require('./chunk-UJ7ZTV4J.cjs'),require('./chunk-5XLFPPTY.cjs'),require('./chunk-SDJ3747Q.cjs'),require('./chunk-OF4FPYNI.cjs'),require('./chunk-2RIHC5TZ.cjs'),require('./chunk-GNFE24S7.cjs');Object.defineProperty(exports,"createMultiBoardServerRuntime",{enumerable:true,get:function(){return chunkU6JMXOER_cjs.b}});Object.defineProperty(exports,"createSingleBoardServerRuntime",{enumerable:true,get:function(){return chunkU6JMXOER_cjs.a}});Object.defineProperty(exports,"createHostedBoardQueueLaneRegistry",{enumerable:true,get:function(){return chunkBQJVCCFU_cjs.a}});//# sourceMappingURL=board-live-cards-server-runtime.cjs.map
2
2
  //# sourceMappingURL=board-live-cards-server-runtime.cjs.map
@@ -1,2 +1,2 @@
1
- export{b as createMultiBoardServerRuntime,a as createSingleBoardServerRuntime}from'./chunk-4VZL3GWU.js';import'./chunk-JB4Q2W7I.js';import'./chunk-XYN5D3GL.js';import'./chunk-O5UYCGIN.js';import'./chunk-OEL5P7XE.js';export{a as createHostedBoardQueueLaneRegistry}from'./chunk-7UJQMFVS.js';import'./chunk-FOFGEABN.js';import'./chunk-RKKSVOP2.js';import'./chunk-NTICU4OK.js';import'./chunk-O7NOHKVR.js';import'./chunk-ZJ5M5COT.js';import'./chunk-BVQISI6G.js';import'./chunk-6MD6FVE3.js';import'./chunk-ZA4FS27N.js';import'./chunk-ANKA7HEJ.js';import'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';import'./chunk-RWAEV253.js';import'./chunk-E46UCDYN.js';import'./chunk-M53MX233.js';import'./chunk-MNEOJWPS.js';import'./chunk-7QNEV5S3.js';import'./chunk-BJGK5FNL.js';import'./chunk-NIBLKYXN.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-server-runtime.js.map
1
+ export{b as createMultiBoardServerRuntime,a as createSingleBoardServerRuntime}from'./chunk-4LHFO56U.js';import'./chunk-JB4Q2W7I.js';import'./chunk-XYN5D3GL.js';import'./chunk-O5UYCGIN.js';import'./chunk-CZ6ZFWFT.js';export{a as createHostedBoardQueueLaneRegistry}from'./chunk-7UJQMFVS.js';import'./chunk-FOFGEABN.js';import'./chunk-RKKSVOP2.js';import'./chunk-NTICU4OK.js';import'./chunk-O7NOHKVR.js';import'./chunk-ZJ5M5COT.js';import'./chunk-5U5NMYGT.js';import'./chunk-6MD6FVE3.js';import'./chunk-H5FKNSCO.js';import'./chunk-ANKA7HEJ.js';import'./chunk-44L64VQ2.js';import'./chunk-VGT3TRQG.js';import'./chunk-WDPOGXTY.js';import'./chunk-6M3RIGUH.js';import'./chunk-ATOQP3BD.js';import'./chunk-YT76JNKE.js';import'./chunk-MNEOJWPS.js';import'./chunk-7QNEV5S3.js';import'./chunk-BJGK5FNL.js';import'./chunk-NIBLKYXN.js';import'./chunk-UGB7PC4P.js';import'./chunk-FW4363Y4.js';//# sourceMappingURL=board-live-cards-server-runtime.js.map
2
2
  //# sourceMappingURL=board-live-cards-server-runtime.js.map
@@ -1,2 +1,2 @@
1
- 'use strict';var chunk7W4QQX7S_cjs=require('../chunk-7W4QQX7S.cjs');require('../chunk-G4XXRHL2.cjs'),require('../chunk-LODXIALE.cjs'),require('../chunk-UG55PF75.cjs'),require('../chunk-JHXRGPL7.cjs'),require('../chunk-UJ7ZTV4J.cjs'),require('../chunk-GNFE24S7.cjs');Object.defineProperty(exports,"LocalStorageService",{enumerable:true,get:function(){return chunk7W4QQX7S_cjs.a}});Object.defineProperty(exports,"buildBrowserArtifactsFromRuntime",{enumerable:true,get:function(){return chunk7W4QQX7S_cjs.e}});Object.defineProperty(exports,"createBoardLiveGraphRuntime",{enumerable:true,get:function(){return chunk7W4QQX7S_cjs.b}});Object.defineProperty(exports,"selectAllLiveCardModels",{enumerable:true,get:function(){return chunk7W4QQX7S_cjs.d}});Object.defineProperty(exports,"selectLiveCardModel",{enumerable:true,get:function(){return chunk7W4QQX7S_cjs.c}});//# sourceMappingURL=index.cjs.map
1
+ 'use strict';var chunkFFHG3CFU_cjs=require('../chunk-FFHG3CFU.cjs');require('../chunk-G4XXRHL2.cjs'),require('../chunk-LODXIALE.cjs'),require('../chunk-QBEQL4TL.cjs'),require('../chunk-QEHKMLHA.cjs'),require('../chunk-UJ7ZTV4J.cjs'),require('../chunk-GNFE24S7.cjs');Object.defineProperty(exports,"LocalStorageService",{enumerable:true,get:function(){return chunkFFHG3CFU_cjs.a}});Object.defineProperty(exports,"buildBrowserArtifactsFromRuntime",{enumerable:true,get:function(){return chunkFFHG3CFU_cjs.e}});Object.defineProperty(exports,"createBoardLiveGraphRuntime",{enumerable:true,get:function(){return chunkFFHG3CFU_cjs.b}});Object.defineProperty(exports,"selectAllLiveCardModels",{enumerable:true,get:function(){return chunkFFHG3CFU_cjs.d}});Object.defineProperty(exports,"selectLiveCardModel",{enumerable:true,get:function(){return chunkFFHG3CFU_cjs.c}});//# sourceMappingURL=index.cjs.map
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1,2 +1,2 @@
1
- export{a as LocalStorageService,e as buildBrowserArtifactsFromRuntime,b as createBoardLiveGraphRuntime,d as selectAllLiveCardModels,c as selectLiveCardModel}from'../chunk-7E5NKZIO.js';import'../chunk-VGT3TRQG.js';import'../chunk-WDPOGXTY.js';import'../chunk-E46UCDYN.js';import'../chunk-M53MX233.js';import'../chunk-MNEOJWPS.js';import'../chunk-FW4363Y4.js';//# sourceMappingURL=index.js.map
1
+ export{a as LocalStorageService,e as buildBrowserArtifactsFromRuntime,b as createBoardLiveGraphRuntime,d as selectAllLiveCardModels,c as selectLiveCardModel}from'../chunk-ZCU5O2LR.js';import'../chunk-VGT3TRQG.js';import'../chunk-WDPOGXTY.js';import'../chunk-ATOQP3BD.js';import'../chunk-YT76JNKE.js';import'../chunk-MNEOJWPS.js';import'../chunk-FW4363Y4.js';//# sourceMappingURL=index.js.map
2
2
  //# sourceMappingURL=index.js.map