bosun 0.40.18 → 0.41.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/agent/agent-custom-tools.mjs +23 -5
  2. package/agent/agent-endpoint.mjs +1443 -1429
  3. package/agent/agent-pool.mjs +6 -2
  4. package/agent/primary-agent.mjs +81 -7
  5. package/bench/benchmark-mode.mjs +253 -0
  6. package/bench/benchmark-registry.mjs +347 -0
  7. package/bench/swebench/README.md +91 -0
  8. package/bench/swebench/bosun-swebench.mjs +461 -0
  9. package/cli.mjs +208 -3
  10. package/config/config-doctor.mjs +51 -2
  11. package/config/config.mjs +103 -3
  12. package/github/github-auth-manager.mjs +70 -19
  13. package/infra/library-manager.mjs +1223 -49
  14. package/infra/monitor.mjs +132 -52
  15. package/infra/session-tracker.mjs +13 -3
  16. package/infra/test-runtime.mjs +267 -0
  17. package/kanban/vibe-kanban-wrapper.mjs +0 -0
  18. package/package.json +13 -6
  19. package/server/setup-web-server.mjs +4 -1
  20. package/server/ui-server.mjs +2042 -86
  21. package/task/task-claims.mjs +49 -17
  22. package/task/task-cli-bin.mjs +8 -0
  23. package/task/task-cli.mjs +23 -7
  24. package/task/task-store.mjs +1 -1
  25. package/telegram/get-telegram-chat-id.mjs +0 -0
  26. package/telegram/telegram-sentinel.mjs +0 -0
  27. package/ui/app.js +2 -0
  28. package/ui/components/chat-view.js +18 -1
  29. package/ui/components/workspace-switcher.js +321 -9
  30. package/ui/demo-defaults.js +11746 -9470
  31. package/ui/demo.html +478 -1
  32. package/ui/modules/router.js +2 -0
  33. package/ui/modules/state.js +21 -0
  34. package/ui/modules/voice-client-sdk.js +1 -1
  35. package/ui/modules/voice-client.js +33 -2
  36. package/ui/styles/components.css +514 -1
  37. package/ui/tabs/benchmarks.js +845 -0
  38. package/ui/tabs/library.js +554 -40
  39. package/ui/tabs/tasks.js +1052 -506
  40. package/ui/tabs/workflow-canvas-utils.mjs +30 -0
  41. package/ui/tabs/workflows.js +914 -298
  42. package/voice/voice-agents-sdk.mjs +1 -1
  43. package/voice/voice-relay.mjs +24 -16
  44. package/workflow/project-detection.mjs +559 -0
  45. package/workflow/workflow-contract.mjs +433 -232
  46. package/workflow/workflow-engine.mjs +184 -27
  47. package/workflow/workflow-nodes.mjs +511 -10
  48. package/workflow/workflow-templates.mjs +92 -16
  49. package/workflow-templates/agents.mjs +20 -19
  50. package/workflow-templates/code-quality.mjs +20 -14
  51. package/workflow-templates/task-batch.mjs +3 -2
  52. package/workflow-templates/task-execution.mjs +752 -0
  53. package/workflow-templates/task-lifecycle.mjs +34 -8
  54. package/workspace/shared-state-manager.mjs +70 -8
  55. package/workspace/shared-workspace-cli.mjs +0 -0
  56. package/workspace/workspace-manager.mjs +151 -0
  57. package/ui/components/chat-view.js.bak +0 -1
  58. package/ui/tabs/infra.js.bak +0 -1
@@ -561,12 +561,30 @@ export async function invokeCustomTool(rootDir, toolId, args = [], opts = {}) {
561
561
  timeout,
562
562
  maxBuffer: 10 * 1024 * 1024, // 10 MB
563
563
  });
564
- stdout = out.stdout;
565
- stderr = out.stderr;
564
+ // Node versions/environments may resolve promisified execFile as:
565
+ // - { stdout, stderr } (modern child_process custom promisify)
566
+ // - stdout string/buffer only (legacy/mocked fallback)
567
+ // - [stdout, stderr] tuple (some custom wrappers)
568
+ if (out && typeof out === "object" && !Array.isArray(out)) {
569
+ stdout = String(out.stdout ?? "");
570
+ stderr = String(out.stderr ?? "");
571
+ } else if (Array.isArray(out)) {
572
+ stdout = String(out[0] ?? "");
573
+ stderr = String(out[1] ?? "");
574
+ } else {
575
+ stdout = String(out ?? "");
576
+ stderr = "";
577
+ }
566
578
  } catch (err) {
567
- stdout = err.stdout || "";
568
- stderr = err.stderr || err.message || "";
569
- exitCode = err.code ?? 1;
579
+ stdout = String(err?.stdout ?? "");
580
+ stderr = String(err?.stderr ?? err?.message ?? "");
581
+ const numericExit = Number(err?.code);
582
+ const numericStatus = Number(err?.status);
583
+ exitCode = Number.isFinite(numericExit)
584
+ ? numericExit
585
+ : Number.isFinite(numericStatus)
586
+ ? numericStatus
587
+ : 1;
570
588
  }
571
589
 
572
590
  // Record usage non-blocking