substrate-ai 0.19.37 → 0.19.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli/index.js CHANGED
@@ -4,7 +4,7 @@ import { createLogger } from "../logger-KeHncl-f.js";
4
4
  import { createEventBus } from "../helpers-CElYrONe.js";
5
5
  import { AdapterRegistry, BudgetConfigSchema, CURRENT_CONFIG_FORMAT_VERSION, CURRENT_TASK_GRAPH_VERSION, ConfigError, CostTrackerConfigSchema, DEFAULT_CONFIG, DoltClient, DoltNotInstalled, GlobalSettingsSchema, IngestionServer, MonitorDatabaseImpl, OPERATIONAL_FINDING, PartialGlobalSettingsSchema, PartialProviderConfigSchema, ProvidersSchema, RoutingRecommender, STORY_METRICS, TelemetryConfigSchema, addTokenUsage, aggregateTokenUsageForRun, checkDoltInstalled, compareRunMetrics, createAmendmentRun, createConfigSystem, createDecision, createDoltClient, createPipelineRun, getActiveDecisions, getAllCostEntriesFiltered, getBaselineRunMetrics, getDecisionsByCategory, getDecisionsByPhaseForRun, getLatestCompletedRun, getLatestRun, getPipelineRunById, getPlanningCostTotal, getRetryableEscalations, getRunMetrics, getRunningPipelineRuns, getSessionCostSummary, getSessionCostSummaryFiltered, getStoryMetricsForRun, getTokenUsageSummary, incrementRunRestarts, initSchema, initializeDolt, listRunMetrics, loadParentRunDecisions, supersedeDecision, tagRunAsBaseline, updatePipelineRun } from "../dist-BUcEqXA1.js";
6
6
  import "../adapter-registry-DXLMTmfD.js";
7
- import { AdapterTelemetryPersistence, AppError, DoltRepoMapMetaRepository, DoltSymbolRepository, ERR_REPO_MAP_STORAGE_WRITE, EpicIngester, GitClient, GrammarLoader, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SymbolParser, createContextCompiler, createDispatcher, createEventEmitter, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStopAfterGate, createTelemetryAdvisor, formatPhaseCompletionSummary, getFactoryRunSummaries, getScenarioResultsForRun, getTwinRunsForRun, listGraphRuns, registerExportCommand, registerFactoryCommand, registerRunCommand, registerScenariosCommand, resolveStoryKeys, runAnalysisPhase, runPlanningPhase, runSolutioningPhase, validateStopAfterFromConflict } from "../run-AF1jEvEp.js";
7
+ import { AdapterTelemetryPersistence, AppError, DoltRepoMapMetaRepository, DoltSymbolRepository, ERR_REPO_MAP_STORAGE_WRITE, EpicIngester, GitClient, GrammarLoader, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SymbolParser, createContextCompiler, createDispatcher, createEventEmitter, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStopAfterGate, createTelemetryAdvisor, formatPhaseCompletionSummary, getFactoryRunSummaries, getScenarioResultsForRun, getTwinRunsForRun, listGraphRuns, registerExportCommand, registerFactoryCommand, registerRunCommand, registerScenariosCommand, resolveStoryKeys, runAnalysisPhase, runPlanningPhase, runSolutioningPhase, validateStopAfterFromConflict } from "../run-B4IPJI5n.js";
8
8
  import "../errors-BZnrgeyp.js";
9
9
  import "../routing-CcBOCuC9.js";
10
10
  import "../decisions-C0pz9Clx.js";
@@ -4833,7 +4833,7 @@ async function runSupervisorAction(options, deps = {}) {
4833
4833
  await initSchema(expAdapter);
4834
4834
  const { runRunAction: runPipeline } = await import(
4835
4835
  /* @vite-ignore */
4836
- "../run-CG9c7xzB.js"
4836
+ "../run-kNOmUhKx.js"
4837
4837
  );
4838
4838
  const runStoryFn = async (opts) => {
4839
4839
  const exitCode = await runPipeline({
@@ -4891,11 +4891,17 @@ function runBuildVerification(options) {
4891
4891
  }
4892
4892
  const timeoutMs = verifyTimeoutMs ?? DEFAULT_VERIFY_TIMEOUT_MS;
4893
4893
  try {
4894
+ const binPath = join$1(projectRoot, "node_modules", ".bin");
4895
+ const envPath = `${binPath}${process.platform === "win32" ? ";" : ":"}${process.env.PATH ?? ""}`;
4894
4896
  const stdout = execSync(cmd, {
4895
4897
  cwd: projectRoot,
4896
4898
  timeout: timeoutMs,
4897
4899
  encoding: "utf-8",
4898
- shell: process.env.SHELL || "/bin/bash"
4900
+ shell: process.env.SHELL || "/bin/bash",
4901
+ env: {
4902
+ ...process.env,
4903
+ PATH: envPath
4904
+ }
4899
4905
  });
4900
4906
  return {
4901
4907
  status: "passed",
@@ -11546,6 +11552,7 @@ function createImplementationOrchestrator(deps) {
11546
11552
  if (!_phaseEndMs.has(storyKey)) _phaseEndMs.set(storyKey, new Map());
11547
11553
  _phaseEndMs.get(storyKey).set(phase, Date.now());
11548
11554
  _completedDispatches++;
11555
+ recordDispatchAgent(storyKey, phase, agentId ?? "claude-code");
11549
11556
  }
11550
11557
  function incrementDispatches(storyKey) {
11551
11558
  _storyDispatches.set(storyKey, (_storyDispatches.get(storyKey) ?? 0) + 1);
@@ -11636,7 +11643,7 @@ function createImplementationOrchestrator(deps) {
11636
11643
  cost_usd: tokenAgg.cost,
11637
11644
  review_cycles: reviewCycles,
11638
11645
  dispatches: _storyDispatches.get(storyKey) ?? 0,
11639
- primary_agent_id: storyAgentId ?? agentId ?? void 0,
11646
+ primary_agent_id: storyAgentId ?? agentId ?? "claude-code",
11640
11647
  dispatch_agents_json: _storyAgents.has(storyKey) ? JSON.stringify(_storyAgents.get(storyKey)) : void 0
11641
11648
  });
11642
11649
  if (stateStore !== void 0) stateStore.recordMetric({
@@ -18354,13 +18361,24 @@ const logger$2 = createLogger("mesh-reporter");
18354
18361
  let _cachedVersion;
18355
18362
  function getSubstrateVersion() {
18356
18363
  if (_cachedVersion !== void 0) return _cachedVersion;
18364
+ const candidates = [];
18357
18365
  try {
18358
18366
  const __dirname = dirname$1(fileURLToPath(import.meta.url));
18359
- const pkg = JSON.parse(readFileSync(join$1(__dirname, "..", "..", "..", "package.json"), "utf-8"));
18360
- _cachedVersion = pkg.version;
18361
- } catch {
18362
- _cachedVersion = "unknown";
18367
+ candidates.push(join$1(__dirname, "..", "..", "..", "package.json"));
18368
+ } catch {}
18369
+ if (process.argv[1]) {
18370
+ const cliDir = dirname$1(process.argv[1]);
18371
+ candidates.push(join$1(cliDir, "..", "package.json"));
18372
+ candidates.push(join$1(cliDir, "..", "..", "package.json"));
18363
18373
  }
18374
+ for (const candidate of candidates) try {
18375
+ const pkg = JSON.parse(readFileSync(candidate, "utf-8"));
18376
+ if (pkg.version && (pkg.name === "substrate-ai" || pkg.name === "substrate")) {
18377
+ _cachedVersion = pkg.version;
18378
+ return _cachedVersion;
18379
+ }
18380
+ } catch {}
18381
+ _cachedVersion = "unknown";
18364
18382
  return _cachedVersion;
18365
18383
  }
18366
18384
  async function loadVerificationResults(runId, runsDir) {
@@ -42727,4 +42745,4 @@ function registerRunCommand(program, _version = "0.0.0", projectRoot = process.c
42727
42745
 
42728
42746
  //#endregion
42729
42747
  export { AdapterTelemetryPersistence, AppError, DoltRepoMapMetaRepository, DoltSymbolRepository, ERR_REPO_MAP_STORAGE_WRITE, EpicIngester, GitClient, GrammarLoader, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SymbolParser, createContextCompiler, createDispatcher, createEventEmitter, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStopAfterGate, createTelemetryAdvisor, formatPhaseCompletionSummary, getFactoryRunSummaries, getScenarioResultsForRun, getTwinRunsForRun, listGraphRuns, normalizeGraphSummaryToStatus, registerExportCommand, registerFactoryCommand, registerRunCommand, registerScenariosCommand, resolveMaxReviewCycles, resolveStoryKeys, runAnalysisPhase, runPlanningPhase, runRunAction, runSolutioningPhase, validateStopAfterFromConflict, wireNdjsonEmitter };
42730
- //# sourceMappingURL=run-AF1jEvEp.js.map
42748
+ //# sourceMappingURL=run-B4IPJI5n.js.map
@@ -2,7 +2,7 @@ import "./health-DMu0MJ-N.js";
2
2
  import "./logger-KeHncl-f.js";
3
3
  import "./helpers-CElYrONe.js";
4
4
  import "./dist-BUcEqXA1.js";
5
- import { normalizeGraphSummaryToStatus, registerRunCommand, resolveMaxReviewCycles, runRunAction, wireNdjsonEmitter } from "./run-AF1jEvEp.js";
5
+ import { normalizeGraphSummaryToStatus, registerRunCommand, resolveMaxReviewCycles, runRunAction, wireNdjsonEmitter } from "./run-B4IPJI5n.js";
6
6
  import "./routing-CcBOCuC9.js";
7
7
  import "./decisions-C0pz9Clx.js";
8
8
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "substrate-ai",
3
- "version": "0.19.37",
3
+ "version": "0.19.39",
4
4
  "description": "Substrate — multi-agent orchestration daemon for AI coding agents",
5
5
  "type": "module",
6
6
  "license": "MIT",