@lazyingart/agintiflow 0.20.280 → 0.20.281
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lazyingart/agintiflow",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.281",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "AgInTiFlow is a project-aware agent workspace for hybrid wet-dry R&D, hardware-aware intelligence, software automation, and industrial workflows.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -2782,6 +2782,16 @@ try {
|
|
|
2782
2782
|
acceptanceClassification.substantiveTest === true,
|
|
2783
2783
|
"a structurally named Python acceptance validator was treated as an arbitrary mutating script"
|
|
2784
2784
|
);
|
|
2785
|
+
const externalAcceptanceValidator =
|
|
2786
|
+
"/opt/conda/bin/python /tmp/supervision/acceptance/webapp_booking_contract.py";
|
|
2787
|
+
const externalAcceptanceClassification = classifyCommand(externalAcceptanceValidator);
|
|
2788
|
+
assert(
|
|
2789
|
+
externalAcceptanceClassification.category === "general-shell" &&
|
|
2790
|
+
externalAcceptanceClassification.writesWorkspace === true &&
|
|
2791
|
+
externalAcceptanceClassification.mayMutateProject === true &&
|
|
2792
|
+
externalAcceptanceClassification.semanticMayMutateProject === false,
|
|
2793
|
+
"trusted-shell authorization for an external Python validator was conflated with project mutation"
|
|
2794
|
+
);
|
|
2785
2795
|
assert(
|
|
2786
2796
|
classifyCommand(`${acceptanceValidator} --output report.json`).writesWorkspace === true,
|
|
2787
2797
|
"a Python acceptance validator with an explicit output destination was treated as read-only"
|
|
@@ -3679,6 +3689,32 @@ try {
|
|
|
3679
3689
|
readOnlyValidatorResult.projectMutationRevision === 0,
|
|
3680
3690
|
"a semantically read-only validator fabricated project mutation progress"
|
|
3681
3691
|
);
|
|
3692
|
+
const externalReadOnlyValidatorState = { meta: { goalContract: { revision: 1 } } };
|
|
3693
|
+
const externalReadOnlyValidatorCommand =
|
|
3694
|
+
"cd . && /opt/conda/bin/python /tmp/supervision/acceptance/webapp_booking_contract.py && git status --short";
|
|
3695
|
+
const externalReadOnlyValidatorResult = {
|
|
3696
|
+
toolName: "run_command",
|
|
3697
|
+
ok: true,
|
|
3698
|
+
exitCode: 0,
|
|
3699
|
+
args: { command: externalReadOnlyValidatorCommand },
|
|
3700
|
+
stdout: "webapp booking contract: PASS\n",
|
|
3701
|
+
stderr: "",
|
|
3702
|
+
commandPolicy: classifyCommand(externalReadOnlyValidatorCommand),
|
|
3703
|
+
};
|
|
3704
|
+
recordProjectVerificationOutcome(
|
|
3705
|
+
externalReadOnlyValidatorState,
|
|
3706
|
+
externalReadOnlyValidatorResult,
|
|
3707
|
+
{
|
|
3708
|
+
commandCwd: workspace,
|
|
3709
|
+
taskProfile: "app",
|
|
3710
|
+
sandboxMode: "host",
|
|
3711
|
+
}
|
|
3712
|
+
);
|
|
3713
|
+
assert(
|
|
3714
|
+
externalReadOnlyValidatorState.meta.projectVerification?.mutationRevision === 0 &&
|
|
3715
|
+
externalReadOnlyValidatorResult.projectMutationRevision === 0,
|
|
3716
|
+
"an absolute-interpreter acceptance validator forced a post-validation commit"
|
|
3717
|
+
);
|
|
3682
3718
|
const shellMutationState = { meta: { goalContract: { revision: 1 } } };
|
|
3683
3719
|
const shellMutationResult = {
|
|
3684
3720
|
toolName: "run_command",
|
package/src/agent-runner.js
CHANGED
|
@@ -10110,6 +10110,12 @@ function commandCanMutateProjectContent(command = "", commandPolicy = {}) {
|
|
|
10110
10110
|
const category = String(commandPolicy.category || "");
|
|
10111
10111
|
const requiresGitMutationInspection =
|
|
10112
10112
|
["git-workflow", "git-remote"].includes(category);
|
|
10113
|
+
if (
|
|
10114
|
+
commandPolicy.semanticMayMutateProject === false &&
|
|
10115
|
+
!requiresGitMutationInspection
|
|
10116
|
+
) {
|
|
10117
|
+
return false;
|
|
10118
|
+
}
|
|
10113
10119
|
if (requiresGitMutationInspection && commandPolicy.gitOnly === true) {
|
|
10114
10120
|
return inferGitActionsFromCommand(command, { requireFailurePropagation: false }).some((action) =>
|
|
10115
10121
|
WORKTREE_CHANGING_GIT_ACTIONS.has(action)
|
package/src/command-policy.js
CHANGED
|
@@ -293,8 +293,9 @@ function delegatedValidationPlanClassification(tokens = []) {
|
|
|
293
293
|
const args = tokens.slice(1).map((token) => String(token || ""));
|
|
294
294
|
const executablePath = validationExecutablePathMetadata(tokens[0]);
|
|
295
295
|
const basenameCommand = [executable, ...args].join(" ");
|
|
296
|
+
const structuredValidation = structuredValidationCommand(basenameCommand);
|
|
296
297
|
const validationLike = Boolean(
|
|
297
|
-
|
|
298
|
+
structuredValidation || matchAny(TEST_PATTERNS, basenameCommand)
|
|
298
299
|
);
|
|
299
300
|
if (executablePath.outsideWorkspace && validationLike) {
|
|
300
301
|
return {
|
|
@@ -302,6 +303,12 @@ function delegatedValidationPlanClassification(tokens = []) {
|
|
|
302
303
|
needsNetwork: true,
|
|
303
304
|
writesWorkspace: true,
|
|
304
305
|
mayMutateProject: true,
|
|
306
|
+
// Requiring trusted-shell authorization for an external executable does
|
|
307
|
+
// not prove that its bounded validation invocation mutates the project.
|
|
308
|
+
// Preserve that semantic distinction for post-command evidence tracking.
|
|
309
|
+
semanticMayMutateProject:
|
|
310
|
+
structuredValidation?.mayMutateProject ??
|
|
311
|
+
validationCommandMayMutateProject(basenameCommand),
|
|
305
312
|
substantiveTest: false,
|
|
306
313
|
reason:
|
|
307
314
|
"The validation executable is outside the current workspace and requires trusted shell policy.",
|