@bridge_gpt/mcp-server 0.2.75 → 0.2.77
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/README.md +8 -6
- package/build/agents.generated.js +5 -5
- package/build/cli-dispatch.js +333 -0
- package/build/codex-auto-recovery.js +25 -7
- package/build/commands.generated.js +8 -8
- package/build/conductor/bridge-api-client.js +193 -13
- package/build/conductor/declare-blocked.js +146 -7
- package/build/conductor/driver-pass.js +8 -0
- package/build/conductor/driver-register.js +8 -2
- package/build/conductor/epic-implementer-cli.js +15 -10
- package/build/conductor/epic-server-journal.js +52 -22
- package/build/conductor/epic-server-recipe.js +15 -5
- package/build/conductor/epic-server-runtime.js +163 -45
- package/build/conductor/epic-server.js +13 -6
- package/build/conductor/install-doctor.js +30 -2
- package/build/conductor/launch-plan.js +28 -7
- package/build/conductor/local-merge.js +55 -13
- package/build/conductor/pr-ci-producer.js +12 -3
- package/build/conductor/readiness-prerequisites.js +89 -2
- package/build/conductor/readiness-sections.js +46 -13
- package/build/conductor/readiness.js +3 -40
- package/build/conductor/recovery-cli.js +14 -12
- package/build/conductor/repository-workflow-remedy.js +147 -7
- package/build/conductor/ui-readiness.js +224 -0
- package/build/conductor/wait-run-attention.js +9 -4
- package/build/conductor/wait-run-cli.js +9 -2
- package/build/docs.generated.js +67 -4
- package/build/doctor.js +97 -1
- package/build/drive-epic.js +625 -33
- package/build/engine-paths.js +10 -0
- package/build/epic-coherence-input-cli.js +105 -10
- package/build/epic-coherence-input.js +877 -4
- package/build/epic-coherence-input.test-fixtures.js +117 -0
- package/build/epic-implementer-bin.js +947 -120
- package/build/epic-implementer-env.js +2 -2
- package/build/epic-launch-context.js +8 -1
- package/build/epic-shared/cut-protocol.js +55 -3
- package/build/executor/completion-contract.js +14 -1
- package/build/executor/failure-reason-codes.js +2 -0
- package/build/executor/guarded-fast-forward-push.js +25 -2
- package/build/executor/integration-job.js +56 -2
- package/build/executor/job-runner.js +87 -28
- package/build/executor/likely-tests.js +78 -6
- package/build/executor/merge-job.js +45 -1
- package/build/executor/permissions.js +187 -2
- package/build/executor/provider-checks.js +101 -5
- package/build/executor/rebase-finalization.js +29 -27
- package/build/executor/reconcile-overlap-job.js +70 -17
- package/build/executor/rename-aside.js +265 -0
- package/build/executor/required-work-ledger.js +89 -6
- package/build/executor/resume-pre-spawn.js +32 -8
- package/build/executor/runner.js +26 -4
- package/build/executor/types.js +121 -0
- package/build/executor/worktree.js +39 -2
- package/build/index.js +2500 -495
- package/build/init.js +16 -0
- package/build/install-bridge-conductor-answers.js +4 -0
- package/build/install-bridge-conductor-apply.js +10 -0
- package/build/install-bridge-conductor-assessment.js +84 -0
- package/build/install-bridge-conductor-contracts.js +9 -1
- package/build/install-bridge-conductor-setup.js +103 -3
- package/build/install-bridge-conductor.js +440 -812
- package/build/install-bridge.js +4 -11
- package/build/language-catalog.generated.js +2649 -0
- package/build/mcp-host-config.js +54 -37
- package/build/phase-context-git-probe.js +16 -0
- package/build/pipelines.generated.js +47 -19
- package/build/plan-execution-ledger.js +35 -0
- package/build/plan-generation.js +34 -0
- package/build/plane/build-freshness.js +6 -0
- package/build/plane/cli.js +12 -5
- package/build/plane/plane-freshness.js +43 -26
- package/build/printed-remedy-commands.js +17 -0
- package/build/readiness-prerequisites.generated.js +28 -0
- package/build/readme.generated.js +1 -1
- package/build/run-unit-tests-launcher.js +3 -1
- package/build/secret-redaction.js +3 -0
- package/build/server.js +7946 -0
- package/build/setup-epic.js +41 -8
- package/build/start-tickets-prereqs.js +3 -6
- package/build/test-support/console-guard.js +30 -0
- package/build/test-support/create-preview-world.js +232 -0
- package/build/test-support/module-imports.js +155 -0
- package/build/test-support/server-client.js +96 -0
- package/build/test-support/stdio-server.js +146 -0
- package/build/ticket-delivery.js +65 -0
- package/build/v2-readiness-requirements.js +39 -5
- package/build/version.generated.js +3 -3
- package/build/worktree-core.js +51 -7
- package/docs/EPIC-IMPLEMENTER.md +150 -2
- package/docs/epic-implementer/getting-started.md +5 -1
- package/package.json +3 -3
- package/pipelines/implement-ticket.json +2 -2
- package/pipelines/learn-repository.json +19 -1
package/build/doctor.js
CHANGED
|
@@ -43,7 +43,10 @@ import { createBridgeApiUrls } from "./bridge-api-urls.js";
|
|
|
43
43
|
import { probeToolSurface } from "./tool-surface-gating.js";
|
|
44
44
|
import { readStoredBindingState, resolveBapiCredentials } from "./credential-store.js";
|
|
45
45
|
import { EPIC_LAUNCH_PROFILE_NAME_PATTERN, listEpicLaunchProfiles } from "./epic-launch-profile.js";
|
|
46
|
-
import { CONDUCTOR_DEFAULT_BASE_URL, resolveConductorBridgeApiAccess } from "./conductor/bridge-api-client.js";
|
|
46
|
+
import { CONDUCTOR_DEFAULT_BASE_URL, resolveConductorBridgeApiAccess, fetchConductorReadiness } from "./conductor/bridge-api-client.js";
|
|
47
|
+
import { formatReadinessPrerequisites, overlayReadinessPrerequisites, toolVisibilityStateFromInspection } from "./conductor/readiness-prerequisites.js";
|
|
48
|
+
import { inspectBridgeApiProfileToken } from "./mcp-host-config.js";
|
|
49
|
+
import { EPIC_IMPLEMENTER_PROFILE_TOKEN } from "./conductor/readiness-sections.js";
|
|
47
50
|
import { validateHttpBaseUrl } from "./base-url.js";
|
|
48
51
|
import { getLiveRepositoryConductors, getParseDispatcherHealth, } from "./epic-shared/bridge-client.js";
|
|
49
52
|
import { resolveRequiredStartTicketsRepoName } from "./start-tickets-repo.js";
|
|
@@ -1195,6 +1198,68 @@ export function formatToolSurfaceDiagnosticReport(diag) {
|
|
|
1195
1198
|
return lines.join("\n");
|
|
1196
1199
|
}
|
|
1197
1200
|
// ---------------------------------------------------------------------------
|
|
1201
|
+
// Epic Implementer readiness rows (BAPI-1747) — STRICTLY read-only.
|
|
1202
|
+
//
|
|
1203
|
+
// One GET to `/jira/epic-runs/conductor-readiness` for doctor's resolved
|
|
1204
|
+
// repository, plus a read-only inspection of the project's MCP host configs for
|
|
1205
|
+
// tool visibility. The rows are composed through the same client overlay the
|
|
1206
|
+
// launch preview and install's final verdict use, so all three name the same
|
|
1207
|
+
// prerequisite IDs and gaps. Any failure prints "Couldn't check"; the section
|
|
1208
|
+
// never writes, never migrates credentials, and never changes the exit code.
|
|
1209
|
+
// ---------------------------------------------------------------------------
|
|
1210
|
+
/** Doctor's bound on its one readiness read. */
|
|
1211
|
+
export const RUN_PATH_READINESS_TIMEOUT_MS = 8_000;
|
|
1212
|
+
async function localToolVisibility(deps) {
|
|
1213
|
+
try {
|
|
1214
|
+
return toolVisibilityStateFromInspection(await deps.inspectProfileToken());
|
|
1215
|
+
}
|
|
1216
|
+
catch {
|
|
1217
|
+
return { state: "unknown", reason: "inspection" };
|
|
1218
|
+
}
|
|
1219
|
+
}
|
|
1220
|
+
/** Collect the readiness rows read-only. Never throws. */
|
|
1221
|
+
export async function collectRunPathReadinessDiagnostic(deps) {
|
|
1222
|
+
try {
|
|
1223
|
+
const target = await resolveInstallDoctorTarget(deps);
|
|
1224
|
+
if (!target.repoName)
|
|
1225
|
+
return { state: "unresolved", detail: "no BAPI_REPO_NAME in the environment or project-local MCP configs" };
|
|
1226
|
+
const cred = await resolveBapiCredentials(target.repoName, {
|
|
1227
|
+
env: deps.env, homedir: deps.homedir, platform: deps.platform,
|
|
1228
|
+
readFile: deps.readFile, stat: deps.stat, stderr: () => { },
|
|
1229
|
+
});
|
|
1230
|
+
if (!cred.ok)
|
|
1231
|
+
return { state: "unresolved", detail: `no Bridge API credential resolved (${cred.kind})` };
|
|
1232
|
+
// Doctor bounds this one read well below the client's 60s readiness timeout.
|
|
1233
|
+
const bounded = (url, init) => deps.fetch(url, { ...init, signal: AbortSignal.any([init.signal, AbortSignal.timeout(RUN_PATH_READINESS_TIMEOUT_MS)]) });
|
|
1234
|
+
const readiness = await fetchConductorReadiness({ repoName: target.repoName, apiKey: cred.credentials.apiKey, baseUrl: target.baseUrl }, bounded);
|
|
1235
|
+
const toolVisibility = await localToolVisibility(deps);
|
|
1236
|
+
return {
|
|
1237
|
+
state: "read",
|
|
1238
|
+
repoName: target.repoName,
|
|
1239
|
+
prerequisites: overlayReadinessPrerequisites([], readiness.prerequisites ?? [], toolVisibility),
|
|
1240
|
+
};
|
|
1241
|
+
}
|
|
1242
|
+
catch {
|
|
1243
|
+
return { state: "failed" };
|
|
1244
|
+
}
|
|
1245
|
+
}
|
|
1246
|
+
/** Render the advisory readiness section (pure formatting). */
|
|
1247
|
+
export function formatRunPathReadinessReport(diag) {
|
|
1248
|
+
const lines = ["", "Epic Implementer readiness (read-only — advisory)", ""];
|
|
1249
|
+
if (diag.state === "read") {
|
|
1250
|
+
lines.push(`Repository: ${diag.repoName}`);
|
|
1251
|
+
lines.push(...formatReadinessPrerequisites(diag.prerequisites, { isProduction: true }));
|
|
1252
|
+
}
|
|
1253
|
+
else if (diag.state === "unresolved") {
|
|
1254
|
+
lines.push(`Couldn't check: ${diag.detail}.`);
|
|
1255
|
+
}
|
|
1256
|
+
else {
|
|
1257
|
+
lines.push("Couldn't check: the readiness read failed. Retry doctor, or run the launch preview.");
|
|
1258
|
+
}
|
|
1259
|
+
lines.push("", "This section is advisory and never changes the exit code.");
|
|
1260
|
+
return lines.join("\n");
|
|
1261
|
+
}
|
|
1262
|
+
// ---------------------------------------------------------------------------
|
|
1198
1263
|
// Executor provisioning diagnostics (BAPI-688) — STRICTLY read-only.
|
|
1199
1264
|
//
|
|
1200
1265
|
// Enumerates the deterministic, convention-named executor service units this
|
|
@@ -2382,6 +2447,37 @@ export async function runDoctorCli(argv, overrides = {}) {
|
|
|
2382
2447
|
}));
|
|
2383
2448
|
}
|
|
2384
2449
|
}
|
|
2450
|
+
// Advisory Epic Implementer readiness section (BAPI-1747). Strictly read-only:
|
|
2451
|
+
// one readiness GET and a host-config read. Any failure prints "Couldn't check"
|
|
2452
|
+
// and never affects the exit code.
|
|
2453
|
+
if (overrides.runPathReadiness !== false) {
|
|
2454
|
+
try {
|
|
2455
|
+
const injectedFs = deps;
|
|
2456
|
+
const o = overrides.runPathReadiness ?? {};
|
|
2457
|
+
const readFileImpl = o.readFile ?? injectedFs.readFile ?? ((p) => readFile(p, "utf-8"));
|
|
2458
|
+
const cwd = o.cwd ?? deps.cwd;
|
|
2459
|
+
const readinessDeps = {
|
|
2460
|
+
env: o.env ?? deps.env,
|
|
2461
|
+
cwd,
|
|
2462
|
+
platform: o.platform ?? deps.platform,
|
|
2463
|
+
homedir: o.homedir ?? injectedFs.homedir ?? os.homedir,
|
|
2464
|
+
readFile: readFileImpl,
|
|
2465
|
+
stat: o.stat ?? injectedFs.stat ?? ((p) => stat(p)),
|
|
2466
|
+
fetch: o.fetch ?? ((url, init) => fetch(url, init)),
|
|
2467
|
+
inspectProfileToken: o.inspectProfileToken ??
|
|
2468
|
+
(() => inspectBridgeApiProfileToken(cwd, EPIC_IMPLEMENTER_PROFILE_TOKEN, { readFile: readFileImpl })),
|
|
2469
|
+
};
|
|
2470
|
+
log(formatRunPathReadinessReport(await collectRunPathReadinessDiagnostic(readinessDeps)));
|
|
2471
|
+
}
|
|
2472
|
+
catch {
|
|
2473
|
+
try {
|
|
2474
|
+
log(formatRunPathReadinessReport({ state: "failed" }));
|
|
2475
|
+
}
|
|
2476
|
+
catch {
|
|
2477
|
+
/* advisory; never block the doctor report */
|
|
2478
|
+
}
|
|
2479
|
+
}
|
|
2480
|
+
}
|
|
2385
2481
|
// Advisory executor-provisioning section (BAPI-688). Strictly read-only: it
|
|
2386
2482
|
// enumerates convention-named units under a fixed OS directory, parses their
|
|
2387
2483
|
// non-secret configuration, and probes credential resolution WITHOUT retaining
|