@probelabs/visor 0.1.82 → 0.1.84
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/defaults/.visor.yaml +4 -4
- package/dist/check-execution-engine.d.ts +5 -0
- package/dist/check-execution-engine.d.ts.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/defaults/.visor.yaml +4 -4
- package/dist/failure-condition-evaluator.d.ts.map +1 -1
- package/dist/generated/config-schema.d.ts +6 -2
- package/dist/generated/config-schema.d.ts.map +1 -1
- package/dist/generated/config-schema.json +9 -2
- package/dist/index.js +39774 -36632
- package/dist/output/code-review/schema.json +2 -2
- package/dist/providers/command-check-provider.d.ts.map +1 -1
- package/dist/sdk/{check-execution-engine-PO5XKTHP.mjs → check-execution-engine-X7VCV6KI.mjs} +2 -2
- package/dist/sdk/{chunk-G24UL45Z.mjs → chunk-Q55L5EPS.mjs} +150 -29
- package/dist/sdk/chunk-Q55L5EPS.mjs.map +1 -0
- package/dist/sdk/sdk.d.mts +4 -2
- package/dist/sdk/sdk.d.ts +4 -2
- package/dist/sdk/sdk.js +169 -33
- package/dist/sdk/sdk.js.map +1 -1
- package/dist/sdk/sdk.mjs +22 -7
- package/dist/sdk/sdk.mjs.map +1 -1
- package/dist/types/config.d.ts +4 -2
- package/dist/types/config.d.ts.map +1 -1
- package/package.json +2 -2
- package/dist/sdk/chunk-G24UL45Z.mjs.map +0 -1
- /package/dist/sdk/{check-execution-engine-PO5XKTHP.mjs.map → check-execution-engine-X7VCV6KI.mjs.map} +0 -0
package/dist/sdk/sdk.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CheckExecutionEngine,
|
|
3
3
|
logger
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-Q55L5EPS.mjs";
|
|
5
5
|
import "./chunk-FIL2OGF6.mjs";
|
|
6
6
|
import {
|
|
7
7
|
ConfigMerger
|
|
@@ -215,6 +215,10 @@ var init_config_schema = __esm({
|
|
|
215
215
|
$ref: "#/definitions/EnvConfig",
|
|
216
216
|
description: "Environment variables for this check"
|
|
217
217
|
},
|
|
218
|
+
timeout: {
|
|
219
|
+
type: "number",
|
|
220
|
+
description: "Timeout in seconds for command execution (default: 60)"
|
|
221
|
+
},
|
|
218
222
|
depends_on: {
|
|
219
223
|
type: "array",
|
|
220
224
|
items: {
|
|
@@ -246,8 +250,8 @@ var init_config_schema = __esm({
|
|
|
246
250
|
description: "Condition to determine if check should run - runs if expression evaluates to true"
|
|
247
251
|
},
|
|
248
252
|
reuse_ai_session: {
|
|
249
|
-
type: "boolean",
|
|
250
|
-
description: "
|
|
253
|
+
type: ["string", "boolean"],
|
|
254
|
+
description: "Check name to reuse AI session from, or true to use first dependency (only works with depends_on)"
|
|
251
255
|
},
|
|
252
256
|
fail_if: {
|
|
253
257
|
type: "string",
|
|
@@ -1572,7 +1576,7 @@ var ConfigManager = class {
|
|
|
1572
1576
|
if (!checkConfig.type) {
|
|
1573
1577
|
checkConfig.type = "ai";
|
|
1574
1578
|
}
|
|
1575
|
-
this.validateCheckConfig(checkName, checkConfig, errors);
|
|
1579
|
+
this.validateCheckConfig(checkName, checkConfig, errors, config);
|
|
1576
1580
|
if (checkConfig.ai_mcp_servers) {
|
|
1577
1581
|
this.validateMcpServersObject(
|
|
1578
1582
|
checkConfig.ai_mcp_servers,
|
|
@@ -1672,7 +1676,7 @@ var ConfigManager = class {
|
|
|
1672
1676
|
/**
|
|
1673
1677
|
* Validate individual check configuration
|
|
1674
1678
|
*/
|
|
1675
|
-
validateCheckConfig(checkName, checkConfig, errors) {
|
|
1679
|
+
validateCheckConfig(checkName, checkConfig, errors, config) {
|
|
1676
1680
|
if (!checkConfig.type) {
|
|
1677
1681
|
checkConfig.type = "ai";
|
|
1678
1682
|
}
|
|
@@ -1753,12 +1757,23 @@ var ConfigManager = class {
|
|
|
1753
1757
|
}
|
|
1754
1758
|
}
|
|
1755
1759
|
if (checkConfig.reuse_ai_session !== void 0) {
|
|
1756
|
-
|
|
1760
|
+
const isString = typeof checkConfig.reuse_ai_session === "string";
|
|
1761
|
+
const isBoolean = typeof checkConfig.reuse_ai_session === "boolean";
|
|
1762
|
+
if (!isString && !isBoolean) {
|
|
1757
1763
|
errors.push({
|
|
1758
1764
|
field: `checks.${checkName}.reuse_ai_session`,
|
|
1759
|
-
message: `Invalid reuse_ai_session value for "${checkName}": must be boolean`,
|
|
1765
|
+
message: `Invalid reuse_ai_session value for "${checkName}": must be string (check name) or boolean`,
|
|
1760
1766
|
value: checkConfig.reuse_ai_session
|
|
1761
1767
|
});
|
|
1768
|
+
} else if (isString) {
|
|
1769
|
+
const targetCheckName = checkConfig.reuse_ai_session;
|
|
1770
|
+
if (!config?.checks || !config.checks[targetCheckName]) {
|
|
1771
|
+
errors.push({
|
|
1772
|
+
field: `checks.${checkName}.reuse_ai_session`,
|
|
1773
|
+
message: `Check "${checkName}" references non-existent check "${targetCheckName}" for session reuse`,
|
|
1774
|
+
value: checkConfig.reuse_ai_session
|
|
1775
|
+
});
|
|
1776
|
+
}
|
|
1762
1777
|
} else if (checkConfig.reuse_ai_session === true) {
|
|
1763
1778
|
if (!checkConfig.depends_on || !Array.isArray(checkConfig.depends_on) || checkConfig.depends_on.length === 0) {
|
|
1764
1779
|
errors.push({
|