@probelabs/visor 0.1.146 → 0.1.147
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/ai-review-service.d.ts.map +1 -1
- package/dist/cli-main.d.ts.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/github-auth.d.ts +40 -0
- package/dist/github-auth.d.ts.map +1 -1
- package/dist/index.js +719 -329
- package/dist/output/traces/{run-2026-02-26T07-50-40-741Z.ndjson → run-2026-02-27T11-27-22-261Z.ndjson} +84 -84
- package/dist/{traces/run-2026-02-26T07-51-32-586Z.ndjson → output/traces/run-2026-02-27T11-28-08-546Z.ndjson} +1090 -1090
- package/dist/sandbox/bubblewrap-sandbox.d.ts +2 -1
- package/dist/sandbox/bubblewrap-sandbox.d.ts.map +1 -1
- package/dist/sandbox/seatbelt-sandbox.d.ts +2 -1
- package/dist/sandbox/seatbelt-sandbox.d.ts.map +1 -1
- package/dist/scheduler/scheduler.d.ts.map +1 -1
- package/dist/sdk/{check-provider-registry-TSAMMJ7Q.mjs → check-provider-registry-CDL5AJSI.mjs} +7 -7
- package/dist/sdk/{check-provider-registry-WSFL2SVQ.mjs → check-provider-registry-CTZA3EVE.mjs} +7 -7
- package/dist/sdk/{check-provider-registry-HK6M4PDQ.mjs → check-provider-registry-SCPM6DIT.mjs} +7 -7
- package/dist/sdk/{chunk-LSCWRTSY.mjs → chunk-2NFKN6CY.mjs} +2 -2
- package/dist/sdk/{chunk-OM3WYVFI.mjs → chunk-4F5UVWAN.mjs} +2 -2
- package/dist/sdk/{chunk-OM3WYVFI.mjs.map → chunk-4F5UVWAN.mjs.map} +1 -1
- package/dist/sdk/{chunk-74YJMONB.mjs → chunk-EWGX7LI7.mjs} +69 -27
- package/dist/sdk/chunk-EWGX7LI7.mjs.map +1 -0
- package/dist/sdk/{chunk-LVOWWALU.mjs → chunk-FBJ7MC7R.mjs} +3 -3
- package/dist/sdk/{chunk-4SYQL5UQ.mjs → chunk-H23T7J6Y.mjs} +69 -27
- package/dist/sdk/chunk-H23T7J6Y.mjs.map +1 -0
- package/dist/sdk/{chunk-I42ZCVA5.mjs → chunk-JKWLGLDR.mjs} +3 -3
- package/dist/sdk/{chunk-E6SMU2Z4.mjs → chunk-R77LN3OE.mjs} +69 -27
- package/dist/sdk/chunk-R77LN3OE.mjs.map +1 -0
- package/dist/sdk/{chunk-L3XPYQ6I.mjs → chunk-V2QW6ECX.mjs} +2 -2
- package/dist/sdk/{chunk-YOKAA4IU.mjs → chunk-XNTBSV6M.mjs} +2 -7
- package/dist/sdk/{chunk-YOKAA4IU.mjs.map → chunk-XNTBSV6M.mjs.map} +1 -1
- package/dist/sdk/{chunk-Y4DBNDLQ.mjs → chunk-YQZW3D2V.mjs} +3 -3
- package/dist/sdk/{chunk-Y4DBNDLQ.mjs.map → chunk-YQZW3D2V.mjs.map} +1 -1
- package/dist/sdk/{config-AAB2FL22.mjs → config-G5UU4WXT.mjs} +2 -2
- package/dist/sdk/{failure-condition-evaluator-O464EJMD.mjs → failure-condition-evaluator-2B5WY7QN.mjs} +3 -3
- package/dist/sdk/{failure-condition-evaluator-SMOVMMES.mjs → failure-condition-evaluator-FHNZL2US.mjs} +3 -3
- package/dist/sdk/github-auth-UPBBBOME.mjs +196 -0
- package/dist/sdk/github-auth-UPBBBOME.mjs.map +1 -0
- package/dist/sdk/{github-frontend-4L5YDHM4.mjs → github-frontend-47EU2HBY.mjs} +3 -3
- package/dist/sdk/{github-frontend-MSX6Q2WL.mjs → github-frontend-V3WUHL6E.mjs} +3 -3
- package/dist/sdk/{host-5BJ25CUZ.mjs → host-GVR4UGZ3.mjs} +2 -2
- package/dist/sdk/{host-GYZ7XCLI.mjs → host-UQUQIYFG.mjs} +2 -2
- package/dist/sdk/{routing-CQDKRPTO.mjs → routing-CZ36LVVS.mjs} +4 -4
- package/dist/sdk/{routing-RIHVCEIU.mjs → routing-THIWDEYY.mjs} +4 -4
- package/dist/sdk/{schedule-tool-handler-4YUM6Z5F.mjs → schedule-tool-handler-GEH62OUM.mjs} +7 -7
- package/dist/sdk/{schedule-tool-handler-62K3NGH6.mjs → schedule-tool-handler-KFYNV7HL.mjs} +7 -7
- package/dist/sdk/{schedule-tool-handler-4O2VKNG2.mjs → schedule-tool-handler-QUMAF2DJ.mjs} +7 -7
- package/dist/sdk/sdk.js +52 -15
- package/dist/sdk/sdk.js.map +1 -1
- package/dist/sdk/sdk.mjs +6 -6
- package/dist/sdk/{trace-helpers-QQSTZGDT.mjs → trace-helpers-EHDZ42HH.mjs} +2 -2
- package/dist/sdk/{trace-helpers-AWCFW5KG.mjs → trace-helpers-W7TF5ZKF.mjs} +2 -2
- package/dist/sdk/{workflow-check-provider-OM62QYHF.mjs → workflow-check-provider-3K7732MW.mjs} +7 -7
- package/dist/sdk/{workflow-check-provider-XC7E5OFH.mjs → workflow-check-provider-5453TW65.mjs} +7 -7
- package/dist/sdk/{workflow-check-provider-3N7HDIN6.mjs → workflow-check-provider-HMABCGB5.mjs} +7 -7
- package/dist/slack/socket-runner.d.ts.map +1 -1
- package/dist/test-runner/core/flow-stage.d.ts +2 -1
- package/dist/test-runner/core/flow-stage.d.ts.map +1 -1
- package/dist/test-runner/index.d.ts.map +1 -1
- package/dist/test-runner/validator.d.ts.map +1 -1
- package/dist/traces/{run-2026-02-26T07-50-40-741Z.ndjson → run-2026-02-27T11-27-22-261Z.ndjson} +84 -84
- package/dist/{output/traces/run-2026-02-26T07-51-32-586Z.ndjson → traces/run-2026-02-27T11-28-08-546Z.ndjson} +1090 -1090
- package/dist/utils/worktree-manager.d.ts +11 -1
- package/dist/utils/worktree-manager.d.ts.map +1 -1
- package/package.json +2 -2
- package/dist/sdk/chunk-4SYQL5UQ.mjs.map +0 -1
- package/dist/sdk/chunk-74YJMONB.mjs.map +0 -1
- package/dist/sdk/chunk-E6SMU2Z4.mjs.map +0 -1
- /package/dist/sdk/{check-provider-registry-HK6M4PDQ.mjs.map → check-provider-registry-CDL5AJSI.mjs.map} +0 -0
- /package/dist/sdk/{check-provider-registry-TSAMMJ7Q.mjs.map → check-provider-registry-CTZA3EVE.mjs.map} +0 -0
- /package/dist/sdk/{check-provider-registry-WSFL2SVQ.mjs.map → check-provider-registry-SCPM6DIT.mjs.map} +0 -0
- /package/dist/sdk/{chunk-L3XPYQ6I.mjs.map → chunk-2NFKN6CY.mjs.map} +0 -0
- /package/dist/sdk/{chunk-I42ZCVA5.mjs.map → chunk-FBJ7MC7R.mjs.map} +0 -0
- /package/dist/sdk/{chunk-LVOWWALU.mjs.map → chunk-JKWLGLDR.mjs.map} +0 -0
- /package/dist/sdk/{chunk-LSCWRTSY.mjs.map → chunk-V2QW6ECX.mjs.map} +0 -0
- /package/dist/sdk/{config-AAB2FL22.mjs.map → config-G5UU4WXT.mjs.map} +0 -0
- /package/dist/sdk/{failure-condition-evaluator-O464EJMD.mjs.map → failure-condition-evaluator-2B5WY7QN.mjs.map} +0 -0
- /package/dist/sdk/{failure-condition-evaluator-SMOVMMES.mjs.map → failure-condition-evaluator-FHNZL2US.mjs.map} +0 -0
- /package/dist/sdk/{github-frontend-4L5YDHM4.mjs.map → github-frontend-47EU2HBY.mjs.map} +0 -0
- /package/dist/sdk/{github-frontend-MSX6Q2WL.mjs.map → github-frontend-V3WUHL6E.mjs.map} +0 -0
- /package/dist/sdk/{host-5BJ25CUZ.mjs.map → host-GVR4UGZ3.mjs.map} +0 -0
- /package/dist/sdk/{host-GYZ7XCLI.mjs.map → host-UQUQIYFG.mjs.map} +0 -0
- /package/dist/sdk/{routing-CQDKRPTO.mjs.map → routing-CZ36LVVS.mjs.map} +0 -0
- /package/dist/sdk/{routing-RIHVCEIU.mjs.map → routing-THIWDEYY.mjs.map} +0 -0
- /package/dist/sdk/{schedule-tool-handler-4O2VKNG2.mjs.map → schedule-tool-handler-GEH62OUM.mjs.map} +0 -0
- /package/dist/sdk/{schedule-tool-handler-4YUM6Z5F.mjs.map → schedule-tool-handler-KFYNV7HL.mjs.map} +0 -0
- /package/dist/sdk/{schedule-tool-handler-62K3NGH6.mjs.map → schedule-tool-handler-QUMAF2DJ.mjs.map} +0 -0
- /package/dist/sdk/{trace-helpers-AWCFW5KG.mjs.map → trace-helpers-EHDZ42HH.mjs.map} +0 -0
- /package/dist/sdk/{trace-helpers-QQSTZGDT.mjs.map → trace-helpers-W7TF5ZKF.mjs.map} +0 -0
- /package/dist/sdk/{workflow-check-provider-3N7HDIN6.mjs.map → workflow-check-provider-3K7732MW.mjs.map} +0 -0
- /package/dist/sdk/{workflow-check-provider-OM62QYHF.mjs.map → workflow-check-provider-5453TW65.mjs.map} +0 -0
- /package/dist/sdk/{workflow-check-provider-XC7E5OFH.mjs.map → workflow-check-provider-HMABCGB5.mjs.map} +0 -0
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FailureConditionEvaluator,
|
|
3
3
|
init_failure_condition_evaluator
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-V2QW6ECX.mjs";
|
|
5
5
|
import {
|
|
6
6
|
addEvent,
|
|
7
7
|
init_trace_helpers
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-4F5UVWAN.mjs";
|
|
9
9
|
import {
|
|
10
10
|
createExtendedLiquid,
|
|
11
11
|
init_liquid_extensions
|
|
@@ -1499,4 +1499,4 @@ export {
|
|
|
1499
1499
|
evaluateTransitions,
|
|
1500
1500
|
init_routing
|
|
1501
1501
|
};
|
|
1502
|
-
//# sourceMappingURL=chunk-
|
|
1502
|
+
//# sourceMappingURL=chunk-FBJ7MC7R.mjs.map
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
import {
|
|
2
|
+
generateHumanId,
|
|
3
|
+
init_human_id
|
|
4
|
+
} from "./chunk-KFKHU6CM.mjs";
|
|
1
5
|
import {
|
|
2
6
|
extractFileSections,
|
|
3
7
|
init_markdown,
|
|
@@ -7,10 +11,6 @@ import {
|
|
|
7
11
|
getPromptStateManager,
|
|
8
12
|
init_prompt_state
|
|
9
13
|
} from "./chunk-LG4AUKHB.mjs";
|
|
10
|
-
import {
|
|
11
|
-
generateHumanId,
|
|
12
|
-
init_human_id
|
|
13
|
-
} from "./chunk-KFKHU6CM.mjs";
|
|
14
14
|
import {
|
|
15
15
|
init_tracer_init,
|
|
16
16
|
initializeTracer
|
|
@@ -33,7 +33,7 @@ import {
|
|
|
33
33
|
import {
|
|
34
34
|
config_exports,
|
|
35
35
|
init_config
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-XNTBSV6M.mjs";
|
|
37
37
|
import {
|
|
38
38
|
ScheduleStore,
|
|
39
39
|
buildScheduleToolContext,
|
|
@@ -53,11 +53,11 @@ import {
|
|
|
53
53
|
init_routing,
|
|
54
54
|
init_snapshot_store,
|
|
55
55
|
snapshot_store_exports
|
|
56
|
-
} from "./chunk-
|
|
56
|
+
} from "./chunk-FBJ7MC7R.mjs";
|
|
57
57
|
import {
|
|
58
58
|
FailureConditionEvaluator,
|
|
59
59
|
init_failure_condition_evaluator
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-V2QW6ECX.mjs";
|
|
61
61
|
import {
|
|
62
62
|
addEvent,
|
|
63
63
|
emitNdjsonFallback,
|
|
@@ -68,7 +68,7 @@ import {
|
|
|
68
68
|
setSpanAttributes,
|
|
69
69
|
trace_helpers_exports,
|
|
70
70
|
withActiveSpan
|
|
71
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-4F5UVWAN.mjs";
|
|
72
72
|
import {
|
|
73
73
|
addDiagramBlock,
|
|
74
74
|
init_metrics
|
|
@@ -1576,12 +1576,15 @@ ${"=".repeat(60)}
|
|
|
1576
1576
|
if (!systemPrompt && schema !== "code-review") {
|
|
1577
1577
|
systemPrompt = "You are general assistant, follow user instructions.";
|
|
1578
1578
|
}
|
|
1579
|
+
log(
|
|
1580
|
+
`\u{1F527} AIReviewService config: allowEdit=${this.config.allowEdit}, allowBash=${this.config.allowBash}, promptType=${this.config.promptType}`
|
|
1581
|
+
);
|
|
1579
1582
|
const options = {
|
|
1580
1583
|
sessionId,
|
|
1581
1584
|
// Prefer config promptType, then env override, else fallback to code-review when schema is set
|
|
1582
1585
|
promptType: this.config.promptType && this.config.promptType.trim() ? this.config.promptType.trim() : explicitPromptType ? explicitPromptType : schema === "code-review" ? "code-review-template" : void 0,
|
|
1583
1586
|
allowEdit: false,
|
|
1584
|
-
//
|
|
1587
|
+
// Default: don't allow file modifications
|
|
1585
1588
|
debug: this.config.debug || false,
|
|
1586
1589
|
// Use systemPrompt (native in rc168+) with fallback to customPrompt for backward compat
|
|
1587
1590
|
systemPrompt: systemPrompt || this.config.systemPrompt || this.config.customPrompt
|
|
@@ -1670,6 +1673,9 @@ ${"=".repeat(60)}
|
|
|
1670
1673
|
if (this.config.model) {
|
|
1671
1674
|
options.model = this.config.model;
|
|
1672
1675
|
}
|
|
1676
|
+
log(
|
|
1677
|
+
`\u{1F527} ProbeAgent options: allowEdit=${options.allowEdit}, enableBash=${options.enableBash}, promptType=${options.promptType}`
|
|
1678
|
+
);
|
|
1673
1679
|
const agent = new ProbeAgent(options);
|
|
1674
1680
|
if (typeof agent.initialize === "function") {
|
|
1675
1681
|
await agent.initialize();
|
|
@@ -3947,7 +3953,7 @@ async function executeWorkflowAsTool(workflowId, args, context2, argsOverrides)
|
|
|
3947
3953
|
...args,
|
|
3948
3954
|
...argsOverrides
|
|
3949
3955
|
};
|
|
3950
|
-
const { WorkflowCheckProvider: WorkflowCheckProvider2 } = await import("./workflow-check-provider-
|
|
3956
|
+
const { WorkflowCheckProvider: WorkflowCheckProvider2 } = await import("./workflow-check-provider-HMABCGB5.mjs");
|
|
3951
3957
|
const provider = new WorkflowCheckProvider2();
|
|
3952
3958
|
const checkConfig = {
|
|
3953
3959
|
type: "workflow",
|
|
@@ -8202,7 +8208,7 @@ async function executeCheckWithForEachItems2(checkId, forEachParent, forEachItem
|
|
|
8202
8208
|
}
|
|
8203
8209
|
}
|
|
8204
8210
|
try {
|
|
8205
|
-
const { evaluateTransitions } = await import("./routing-
|
|
8211
|
+
const { evaluateTransitions } = await import("./routing-CZ36LVVS.mjs");
|
|
8206
8212
|
const transTarget = await evaluateTransitions(
|
|
8207
8213
|
onFinish.transitions,
|
|
8208
8214
|
forEachParent,
|
|
@@ -8262,7 +8268,7 @@ async function executeCheckWithForEachItems2(checkId, forEachParent, forEachItem
|
|
|
8262
8268
|
`[LevelDispatch] Error evaluating on_finish transitions for ${forEachParent}: ${e instanceof Error ? e.message : String(e)}`
|
|
8263
8269
|
);
|
|
8264
8270
|
}
|
|
8265
|
-
const { evaluateGoto: evaluateGoto2 } = await import("./routing-
|
|
8271
|
+
const { evaluateGoto: evaluateGoto2 } = await import("./routing-CZ36LVVS.mjs");
|
|
8266
8272
|
if (context2.debug) {
|
|
8267
8273
|
logger.info(
|
|
8268
8274
|
`[LevelDispatch] Evaluating on_finish.goto_js for forEach parent: ${forEachParent}`
|
|
@@ -10662,10 +10668,12 @@ var init_bubblewrap_sandbox = __esm({
|
|
|
10662
10668
|
name;
|
|
10663
10669
|
config;
|
|
10664
10670
|
repoPath;
|
|
10665
|
-
|
|
10671
|
+
visorDistPath;
|
|
10672
|
+
constructor(name, config, repoPath, visorDistPath) {
|
|
10666
10673
|
this.name = name;
|
|
10667
10674
|
this.config = config;
|
|
10668
10675
|
this.repoPath = resolve(repoPath);
|
|
10676
|
+
this.visorDistPath = resolve(visorDistPath);
|
|
10669
10677
|
}
|
|
10670
10678
|
/**
|
|
10671
10679
|
* Check if bwrap binary is available on the system.
|
|
@@ -10746,6 +10754,8 @@ var init_bubblewrap_sandbox = __esm({
|
|
|
10746
10754
|
} else {
|
|
10747
10755
|
args.push("--bind", this.repoPath, workdir);
|
|
10748
10756
|
}
|
|
10757
|
+
const visorPath = this.config.visor_path || "/opt/visor";
|
|
10758
|
+
args.push("--ro-bind", this.visorDistPath, visorPath);
|
|
10749
10759
|
args.push("--chdir", workdir);
|
|
10750
10760
|
args.push("--unshare-pid");
|
|
10751
10761
|
args.push("--new-session");
|
|
@@ -10787,10 +10797,12 @@ var init_seatbelt_sandbox = __esm({
|
|
|
10787
10797
|
name;
|
|
10788
10798
|
config;
|
|
10789
10799
|
repoPath;
|
|
10790
|
-
|
|
10800
|
+
visorDistPath;
|
|
10801
|
+
constructor(name, config, repoPath, visorDistPath) {
|
|
10791
10802
|
this.name = name;
|
|
10792
10803
|
this.config = config;
|
|
10793
10804
|
this.repoPath = realpathSync(resolve2(repoPath));
|
|
10805
|
+
this.visorDistPath = realpathSync(resolve2(visorDistPath));
|
|
10794
10806
|
}
|
|
10795
10807
|
/**
|
|
10796
10808
|
* Check if sandbox-exec binary is available on the system.
|
|
@@ -10891,6 +10903,8 @@ var init_seatbelt_sandbox = __esm({
|
|
|
10891
10903
|
if (!this.config.read_only) {
|
|
10892
10904
|
lines.push(`(allow file-write* (subpath "${repoPath}"))`);
|
|
10893
10905
|
}
|
|
10906
|
+
const visorDistPath = this.escapePath(this.visorDistPath);
|
|
10907
|
+
lines.push(`(allow file-read* (subpath "${visorDistPath}"))`);
|
|
10894
10908
|
if (this.config.network !== false) {
|
|
10895
10909
|
lines.push("(allow network*)");
|
|
10896
10910
|
}
|
|
@@ -10963,13 +10977,13 @@ var init_sandbox_manager = __esm({
|
|
|
10963
10977
|
const mode = config.compose ? "compose" : "image";
|
|
10964
10978
|
if (config.engine === "bubblewrap") {
|
|
10965
10979
|
const { BubblewrapSandbox: BubblewrapSandbox2 } = (init_bubblewrap_sandbox(), __toCommonJS(bubblewrap_sandbox_exports));
|
|
10966
|
-
const instance = new BubblewrapSandbox2(name, config, this.repoPath);
|
|
10980
|
+
const instance = new BubblewrapSandbox2(name, config, this.repoPath, this.visorDistPath);
|
|
10967
10981
|
this.instances.set(name, instance);
|
|
10968
10982
|
return instance;
|
|
10969
10983
|
}
|
|
10970
10984
|
if (config.engine === "seatbelt") {
|
|
10971
10985
|
const { SeatbeltSandbox: SeatbeltSandbox2 } = (init_seatbelt_sandbox(), __toCommonJS(seatbelt_sandbox_exports));
|
|
10972
|
-
const instance = new SeatbeltSandbox2(name, config, this.repoPath);
|
|
10986
|
+
const instance = new SeatbeltSandbox2(name, config, this.repoPath, this.visorDistPath);
|
|
10973
10987
|
this.instances.set(name, instance);
|
|
10974
10988
|
return instance;
|
|
10975
10989
|
}
|
|
@@ -11801,7 +11815,7 @@ var init_state_machine_execution_engine = __esm({
|
|
|
11801
11815
|
try {
|
|
11802
11816
|
const map = options?.webhookContext?.webhookData;
|
|
11803
11817
|
if (map) {
|
|
11804
|
-
const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-
|
|
11818
|
+
const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-CDL5AJSI.mjs");
|
|
11805
11819
|
const reg = CheckProviderRegistry2.getInstance();
|
|
11806
11820
|
const p = reg.getProvider("http_input");
|
|
11807
11821
|
if (p && typeof p.setWebhookContext === "function") p.setWebhookContext(map);
|
|
@@ -11914,7 +11928,7 @@ var init_state_machine_execution_engine = __esm({
|
|
|
11914
11928
|
logger.info("[StateMachine] Using state machine engine");
|
|
11915
11929
|
}
|
|
11916
11930
|
if (!config) {
|
|
11917
|
-
const { ConfigManager } = await import("./config-
|
|
11931
|
+
const { ConfigManager } = await import("./config-G5UU4WXT.mjs");
|
|
11918
11932
|
const configManager = new ConfigManager();
|
|
11919
11933
|
config = await configManager.getDefaultConfig();
|
|
11920
11934
|
logger.debug("[StateMachine] Using default configuration (no config provided)");
|
|
@@ -11924,7 +11938,7 @@ var init_state_machine_execution_engine = __esm({
|
|
|
11924
11938
|
tag_filter: tagFilter
|
|
11925
11939
|
} : config;
|
|
11926
11940
|
try {
|
|
11927
|
-
const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-
|
|
11941
|
+
const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-CDL5AJSI.mjs");
|
|
11928
11942
|
const registry = CheckProviderRegistry2.getInstance();
|
|
11929
11943
|
registry.setCustomTools(configWithTagFilter.tools || {});
|
|
11930
11944
|
} catch (error) {
|
|
@@ -11988,7 +12002,7 @@ var init_state_machine_execution_engine = __esm({
|
|
|
11988
12002
|
try {
|
|
11989
12003
|
const webhookData = this.executionContext?.webhookContext?.webhookData;
|
|
11990
12004
|
if (webhookData instanceof Map) {
|
|
11991
|
-
const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-
|
|
12005
|
+
const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-QUMAF2DJ.mjs");
|
|
11992
12006
|
const slackCtx = extractSlackContext2(webhookData);
|
|
11993
12007
|
if (slackCtx) {
|
|
11994
12008
|
const payload = Array.from(webhookData.values())[0];
|
|
@@ -12017,7 +12031,7 @@ var init_state_machine_execution_engine = __esm({
|
|
|
12017
12031
|
if (Array.isArray(configWithTagFilter.frontends) && configWithTagFilter.frontends.length > 0) {
|
|
12018
12032
|
try {
|
|
12019
12033
|
const { EventBus } = await import("./event-bus-5K3Y2FCS.mjs");
|
|
12020
|
-
const { FrontendsHost } = await import("./host-
|
|
12034
|
+
const { FrontendsHost } = await import("./host-GVR4UGZ3.mjs");
|
|
12021
12035
|
const bus = new EventBus();
|
|
12022
12036
|
context2.eventBus = bus;
|
|
12023
12037
|
frontendsHost = new FrontendsHost(bus, logger);
|
|
@@ -12367,9 +12381,9 @@ var init_state_machine_execution_engine = __esm({
|
|
|
12367
12381
|
* @returns Array of failure condition evaluation results
|
|
12368
12382
|
*/
|
|
12369
12383
|
async evaluateFailureConditions(checkName, reviewSummary, config, previousOutputs, authorAssociation) {
|
|
12370
|
-
const { FailureConditionEvaluator: FailureConditionEvaluator2 } = await import("./failure-condition-evaluator-
|
|
12384
|
+
const { FailureConditionEvaluator: FailureConditionEvaluator2 } = await import("./failure-condition-evaluator-FHNZL2US.mjs");
|
|
12371
12385
|
const evaluator = new FailureConditionEvaluator2();
|
|
12372
|
-
const { addEvent: addEvent3 } = await import("./trace-helpers-
|
|
12386
|
+
const { addEvent: addEvent3 } = await import("./trace-helpers-EHDZ42HH.mjs");
|
|
12373
12387
|
const { addFailIfTriggered } = await import("./metrics-I6A7IHG4.mjs");
|
|
12374
12388
|
const checkConfig = config.checks?.[checkName];
|
|
12375
12389
|
if (!checkConfig) {
|
|
@@ -37694,7 +37708,7 @@ function buildBuiltinGlobals(opts) {
|
|
|
37694
37708
|
const scheduleFn = async (args = {}) => {
|
|
37695
37709
|
try {
|
|
37696
37710
|
const { handleScheduleAction: handleScheduleAction2, buildScheduleToolContext: buildScheduleToolContext2 } = await import("./schedule-tool-2COUUTF7.mjs");
|
|
37697
|
-
const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-
|
|
37711
|
+
const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-QUMAF2DJ.mjs");
|
|
37698
37712
|
const parentCtx = opts.sessionInfo?._parentContext;
|
|
37699
37713
|
const webhookData = parentCtx?.prInfo?.eventContext?.webhookData;
|
|
37700
37714
|
const visorCfg = parentCtx?.config;
|
|
@@ -38365,7 +38379,7 @@ var init_worktree_manager = __esm({
|
|
|
38365
38379
|
/**
|
|
38366
38380
|
* Get or create bare repository
|
|
38367
38381
|
*/
|
|
38368
|
-
async getOrCreateBareRepo(repository, repoUrl,
|
|
38382
|
+
async getOrCreateBareRepo(repository, repoUrl, _token, fetchDepth, cloneTimeoutMs) {
|
|
38369
38383
|
const reposDir = this.getReposDir();
|
|
38370
38384
|
const repoName = repository.replace(/\//g, "-");
|
|
38371
38385
|
const bareRepoPath = path11.join(reposDir, `${repoName}.git`);
|
|
@@ -38381,11 +38395,12 @@ var init_worktree_manager = __esm({
|
|
|
38381
38395
|
);
|
|
38382
38396
|
await fsp2.rm(bareRepoPath, { recursive: true, force: true });
|
|
38383
38397
|
} else {
|
|
38398
|
+
await this.resetBareRepoRemoteUrl(bareRepoPath, repoUrl);
|
|
38384
38399
|
await this.updateBareRepo(bareRepoPath);
|
|
38385
38400
|
return bareRepoPath;
|
|
38386
38401
|
}
|
|
38387
38402
|
}
|
|
38388
|
-
const cloneUrl =
|
|
38403
|
+
const cloneUrl = repoUrl;
|
|
38389
38404
|
const redactedUrl = this.redactUrl(cloneUrl);
|
|
38390
38405
|
logger.info(
|
|
38391
38406
|
`Cloning bare repository: ${redactedUrl}${fetchDepth ? ` (depth: ${fetchDepth})` : ""}`
|
|
@@ -38466,6 +38481,33 @@ var init_worktree_manager = __esm({
|
|
|
38466
38481
|
return false;
|
|
38467
38482
|
}
|
|
38468
38483
|
}
|
|
38484
|
+
/**
|
|
38485
|
+
* Ensure the origin remote URL of a bare repo is a plain URL (no embedded token).
|
|
38486
|
+
*
|
|
38487
|
+
* Older bare repos may have been cloned with a token in the URL
|
|
38488
|
+
* (https://x-access-token:TOKEN@github.com/...). This causes stale-token
|
|
38489
|
+
* failures because GIT_CONFIG insteadOf rules can't rewrite URLs that
|
|
38490
|
+
* already have credentials. Resetting to the plain URL lets insteadOf
|
|
38491
|
+
* handle auth with the freshest token.
|
|
38492
|
+
*/
|
|
38493
|
+
async resetBareRepoRemoteUrl(bareRepoPath, plainRepoUrl) {
|
|
38494
|
+
try {
|
|
38495
|
+
const cmd = `git -C ${this.escapeShellArg(bareRepoPath)} remote set-url origin ${this.escapeShellArg(plainRepoUrl)}`;
|
|
38496
|
+
const result = await this.executeGitCommand(cmd, { timeout: 1e4 });
|
|
38497
|
+
if (result.exitCode !== 0) {
|
|
38498
|
+
logger.warn(
|
|
38499
|
+
`Failed to reset bare repo remote URL: ${result.stderr}. Git operations may fail with stale token if the URL has embedded credentials.`
|
|
38500
|
+
);
|
|
38501
|
+
} else {
|
|
38502
|
+
logger.debug(`Reset bare repo remote URL to plain URL for ${bareRepoPath}`);
|
|
38503
|
+
}
|
|
38504
|
+
} catch (error) {
|
|
38505
|
+
const msg = error instanceof Error ? error.message : String(error);
|
|
38506
|
+
logger.warn(
|
|
38507
|
+
`Error resetting bare repo remote URL: ${msg}. Git operations may fail with stale token if the URL has embedded credentials.`
|
|
38508
|
+
);
|
|
38509
|
+
}
|
|
38510
|
+
}
|
|
38469
38511
|
/**
|
|
38470
38512
|
* Create a new worktree for the given repository/ref.
|
|
38471
38513
|
*
|
|
@@ -40648,4 +40690,4 @@ undici/lib/fetch/body.js:
|
|
|
40648
40690
|
undici/lib/websocket/frame.js:
|
|
40649
40691
|
(*! ws. MIT License. Einar Otto Stangvik <einaros@gmail.com> *)
|
|
40650
40692
|
*/
|
|
40651
|
-
//# sourceMappingURL=chunk-
|
|
40693
|
+
//# sourceMappingURL=chunk-H23T7J6Y.mjs.map
|