substrate-ai 0.4.3 → 0.4.5

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.
@@ -84,6 +84,7 @@ var ClaudeCodeAdapter = class {
84
84
  envEntries.OTEL_EXPORTER_OTLP_ENDPOINT = options.otlpEndpoint;
85
85
  envEntries.OTEL_LOG_TOOL_DETAILS = "1";
86
86
  envEntries.OTEL_METRIC_EXPORT_INTERVAL = "10000";
87
+ envEntries.OTEL_EXPORTER_OTLP_TIMEOUT = "5000";
87
88
  if (options.storyKey !== void 0) envEntries.OTEL_RESOURCE_ATTRIBUTES = `substrate.story_key=${options.storyKey}`;
88
89
  }
89
90
  return {
@@ -824,4 +825,4 @@ var AdapterRegistry = class {
824
825
 
825
826
  //#endregion
826
827
  export { AdapterRegistry, ClaudeCodeAdapter, CodexCLIAdapter, GeminiCLIAdapter };
827
- //# sourceMappingURL=adapter-registry-rSOJ9Kvz.js.map
828
+ //# sourceMappingURL=adapter-registry-Cd-7lG5v.js.map
@@ -0,0 +1,3 @@
1
+ import { AdapterRegistry } from "./adapter-registry-Cd-7lG5v.js";
2
+
3
+ export { AdapterRegistry };
package/dist/cli/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
- import { DEFAULT_CONFIG, DEFAULT_ROUTING_POLICY, DatabaseWrapper, DoltClient, DoltNotInstalled, DoltRepoMapMetaRepository, DoltSymbolRepository, FileStateStore, GitClient, GrammarLoader, IngestionServer, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SUBSTRATE_OWNED_SETTINGS_KEYS, SymbolParser, TelemetryPersistence, VALID_PHASES, buildPipelineStatusOutput, checkDoltInstalled, createConfigSystem, createContextCompiler, createDispatcher, createDoltClient, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStateStore, createStopAfterGate, findPackageRoot, formatOutput, formatPhaseCompletionSummary, formatPipelineStatusHuman, formatPipelineSummary, formatTokenTelemetry, getAllDescendantPids, getAutoHealthData, getSubstrateDefaultSettings, initializeDolt, parseDbTimestampAsUtc, registerHealthCommand, registerRunCommand, resolveBmadMethodSrcPath, resolveBmadMethodVersion, resolveMainRepoRoot, resolveStoryKeys, runAnalysisPhase, runMigrations, runPlanningPhase, runSolutioningPhase, validateStopAfterFromConflict } from "../run-AHblPlOJ.js";
2
+ import { DEFAULT_CONFIG, DEFAULT_ROUTING_POLICY, DatabaseWrapper, DoltClient, DoltNotInstalled, DoltRepoMapMetaRepository, DoltSymbolRepository, FileStateStore, GitClient, GrammarLoader, IngestionServer, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SUBSTRATE_OWNED_SETTINGS_KEYS, SymbolParser, TelemetryPersistence, VALID_PHASES, buildPipelineStatusOutput, checkDoltInstalled, createConfigSystem, createContextCompiler, createDispatcher, createDoltClient, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStateStore, createStopAfterGate, findPackageRoot, formatOutput, formatPhaseCompletionSummary, formatPipelineStatusHuman, formatPipelineSummary, formatTokenTelemetry, getAllDescendantPids, getAutoHealthData, getSubstrateDefaultSettings, initializeDolt, parseDbTimestampAsUtc, registerHealthCommand, registerRunCommand, resolveBmadMethodSrcPath, resolveBmadMethodVersion, resolveMainRepoRoot, resolveStoryKeys, runAnalysisPhase, runMigrations, runPlanningPhase, runSolutioningPhase, validateStopAfterFromConflict } from "../run-B9G5NI16.js";
3
3
  import { createLogger } from "../logger-D2fS2ccL.js";
4
- import { AdapterRegistry } from "../adapter-registry-rSOJ9Kvz.js";
4
+ import { AdapterRegistry } from "../adapter-registry-Cd-7lG5v.js";
5
5
  import { CURRENT_CONFIG_FORMAT_VERSION, CURRENT_TASK_GRAPH_VERSION, PartialSubstrateConfigSchema } from "../config-migrator-DtZW1maj.js";
6
6
  import { ConfigError, createEventBus } from "../helpers-BihqWgVe.js";
7
7
  import { RoutingRecommender } from "../routing-CZfJB3y9.js";
@@ -2312,7 +2312,7 @@ function defaultSupervisorDeps() {
2312
2312
  if (cached === null) {
2313
2313
  const { AdapterRegistry: AR } = await import(
2314
2314
  /* @vite-ignore */
2315
- "../adapter-registry-CctHT8ZH.js"
2315
+ "../adapter-registry-X5X81xdJ.js"
2316
2316
  );
2317
2317
  cached = new AR();
2318
2318
  await cached.discoverAndRegister();
@@ -2709,7 +2709,7 @@ async function runSupervisorAction(options, deps = {}) {
2709
2709
  const expDb = expDbWrapper.db;
2710
2710
  const { runRunAction: runPipeline } = await import(
2711
2711
  /* @vite-ignore */
2712
- "../run-C_mCMW99.js"
2712
+ "../run-CXPqJdGe.js"
2713
2713
  );
2714
2714
  const runStoryFn = async (opts) => {
2715
2715
  const exitCode = await runPipeline({
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { childLogger, createLogger, logger } from "./logger-D2fS2ccL.js";
2
- import { AdapterRegistry, ClaudeCodeAdapter, CodexCLIAdapter, GeminiCLIAdapter } from "./adapter-registry-rSOJ9Kvz.js";
2
+ import { AdapterRegistry, ClaudeCodeAdapter, CodexCLIAdapter, GeminiCLIAdapter } from "./adapter-registry-Cd-7lG5v.js";
3
3
  import { AdtError, BudgetExceededError, ConfigError, ConfigIncompatibleFormatError, GitError, RecoveryError, TaskConfigError, TaskGraphCycleError, TaskGraphError, TaskGraphIncompatibleFormatError, WorkerError, WorkerNotFoundError, assertDefined, createEventBus, createTuiApp, deepClone, formatDuration, generateId, isPlainObject, isTuiCapable, printNonTtyWarning, sleep, withRetry } from "./helpers-BihqWgVe.js";
4
4
 
5
5
  //#region src/core/di.ts
@@ -22,6 +22,7 @@ import { EventEmitter } from "node:events";
22
22
  import { createHash, randomUUID } from "node:crypto";
23
23
  import { freemem, platform } from "node:os";
24
24
  import { createServer } from "node:http";
25
+ import { createGunzip, createInflate } from "node:zlib";
25
26
 
26
27
  //#region rolldown:runtime
27
28
  var __create = Object.create;
@@ -12285,11 +12286,14 @@ var IngestionServer = class {
12285
12286
  res.end(JSON.stringify({ status: "ok" }));
12286
12287
  return;
12287
12288
  }
12289
+ const encoding = req.headers["content-encoding"];
12290
+ let stream = req;
12291
+ if (encoding === "gzip" || encoding === "deflate") stream = encoding === "gzip" ? req.pipe(createGunzip()) : req.pipe(createInflate());
12288
12292
  const chunks = [];
12289
- req.on("data", (chunk) => {
12293
+ stream.on("data", (chunk) => {
12290
12294
  chunks.push(chunk);
12291
12295
  });
12292
- req.on("end", () => {
12296
+ stream.on("end", () => {
12293
12297
  const bodyStr = Buffer.concat(chunks).toString("utf-8");
12294
12298
  logger$7.trace({
12295
12299
  url: req.url,
@@ -12313,10 +12317,12 @@ var IngestionServer = class {
12313
12317
  res.writeHead(200, { "Content-Type": "application/json" });
12314
12318
  res.end("{}");
12315
12319
  });
12316
- req.on("error", (err) => {
12320
+ stream.on("error", (err) => {
12317
12321
  logger$7.warn({ err }, "Error reading OTLP request body");
12318
- res.writeHead(400);
12319
- res.end("Bad Request");
12322
+ if (!res.headersSent) {
12323
+ res.writeHead(400);
12324
+ res.end("Bad Request");
12325
+ }
12320
12326
  });
12321
12327
  }
12322
12328
  };
@@ -21085,4 +21091,4 @@ function registerRunCommand(program, _version = "0.0.0", projectRoot = process.c
21085
21091
 
21086
21092
  //#endregion
21087
21093
  export { DEFAULT_CONFIG, DEFAULT_ROUTING_POLICY, DatabaseWrapper, DoltClient, DoltNotInstalled, DoltRepoMapMetaRepository, DoltSymbolRepository, FileStateStore, GitClient, GrammarLoader, IngestionServer, RepoMapInjector, RepoMapModule, RepoMapQueryEngine, RepoMapStorage, SUBSTRATE_OWNED_SETTINGS_KEYS, SymbolParser, TelemetryPersistence, VALID_PHASES, buildPipelineStatusOutput, checkDoltInstalled, createConfigSystem, createContextCompiler, createDispatcher, createDoltClient, createImplementationOrchestrator, createPackLoader, createPhaseOrchestrator, createStateStore, createStopAfterGate, findPackageRoot, formatOutput, formatPhaseCompletionSummary, formatPipelineStatusHuman, formatPipelineSummary, formatTokenTelemetry, getAllDescendantPids, getAutoHealthData, getSubstrateDefaultSettings, initializeDolt, parseDbTimestampAsUtc, registerHealthCommand, registerRunCommand, resolveBmadMethodSrcPath, resolveBmadMethodVersion, resolveMainRepoRoot, resolveStoryKeys, runAnalysisPhase, runMigrations, runPlanningPhase, runRunAction, runSolutioningPhase, validateStopAfterFromConflict };
21088
- //# sourceMappingURL=run-AHblPlOJ.js.map
21094
+ //# sourceMappingURL=run-B9G5NI16.js.map
@@ -1,4 +1,4 @@
1
- import { registerRunCommand, runRunAction } from "./run-AHblPlOJ.js";
1
+ import { registerRunCommand, runRunAction } from "./run-B9G5NI16.js";
2
2
  import "./logger-D2fS2ccL.js";
3
3
  import "./config-migrator-DtZW1maj.js";
4
4
  import "./helpers-BihqWgVe.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "substrate-ai",
3
- "version": "0.4.3",
3
+ "version": "0.4.5",
4
4
  "description": "Substrate — multi-agent orchestration daemon for AI coding agents",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -1,3 +0,0 @@
1
- import { AdapterRegistry } from "./adapter-registry-rSOJ9Kvz.js";
2
-
3
- export { AdapterRegistry };