agentic-workflow-manager 6.5.1 → 6.5.2

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.
@@ -5,7 +5,17 @@ exports.parseCoverageContract = parseCoverageContract;
5
5
  exports.parseCoverageManifest = parseCoverageManifest;
6
6
  exports.COVERAGE_SCHEMA_VERSION = 1;
7
7
  exports.MAX_COVERAGE_FILE_BYTES = 1024 * 1024;
8
- const SAFE_EVIDENCE_DOTFILES = Object.freeze(['.semgrep.awm.yml', '.dep-cruiser.awm.js']);
8
+ const COVERAGE_EVIDENCE_PATHS = new Set([
9
+ 'eslint.config.awm.mjs',
10
+ 'eslint.config.js',
11
+ 'eslint.config.mjs',
12
+ 'eslint.config.cjs',
13
+ 'eslint.config.ts',
14
+ 'eslint.config.mts',
15
+ 'eslint.config.cts',
16
+ '.semgrep.awm.yml',
17
+ '.dep-cruiser.awm.js',
18
+ ]);
9
19
  function isRecord(value) {
10
20
  return typeof value === 'object' && value !== null && !Array.isArray(value);
11
21
  }
@@ -40,8 +50,8 @@ function safeName(value, source, location) {
40
50
  }
41
51
  function safeEvidenceFilename(value, source, location) {
42
52
  const name = nonEmptyString(value, source, location);
43
- if (name === '.' || name === '..' || name.includes('..') || /[/\\]/.test(name) || !/^[A-Za-z0-9._-]+$/.test(name) || (name.startsWith('.') && !SAFE_EVIDENCE_DOTFILES.includes(name))) {
44
- invalid(source, `${location} must be a safe evidence filename component`);
53
+ if (!COVERAGE_EVIDENCE_PATHS.has(name)) {
54
+ invalid(source, `${location} must be a supported coverage evidence path`);
45
55
  }
46
56
  return name;
47
57
  }
@@ -12,7 +12,7 @@ describe('coverage contract v1', () => {
12
12
  sensor: 'contract-test',
13
13
  evidence: {
14
14
  commandIncludes: ['coverage'],
15
- files: [{ path: 'contract.ts', containsAll: ['parseCoverageContract'] }],
15
+ files: [{ path: 'eslint.config.awm.mjs', containsAll: ['parseCoverageContract'] }],
16
16
  },
17
17
  }],
18
18
  remedy: { summary: 'Add a parser.', command: 'npm test -- contract.test.ts' },
@@ -32,7 +32,7 @@ describe('coverage contract v1', () => {
32
32
  ])('rejects malformed contract %j', (input, message) => {
33
33
  expect(() => (0, contract_1.parseCoverageContract)(input, 'coverage.json')).toThrow(message);
34
34
  });
35
- test.each(['', '.', '..', 'a..b', '../secret', 'a/../../secret', '/etc/passwd', 'C:\\secret', 'a\\..\\secret', ' report.txt', 'report!.txt', 'ñ.txt', '.env', '.gitignore'])('rejects hostile evidence path %p', (path) => {
35
+ test.each(['', '.', '..', 'a..b', '../secret', 'a/../../secret', '/etc/passwd', 'C:\\secret', 'a\\..\\secret', ' report.txt', 'report!.txt', 'ñ.txt', '.env', '.gitignore', 'secrets.txt', 'id_rsa'])('rejects hostile evidence path %p', (path) => {
36
36
  const input = {
37
37
  schemaVersion: 1,
38
38
  classes: {
@@ -45,7 +45,17 @@ describe('coverage contract v1', () => {
45
45
  };
46
46
  expect(() => (0, contract_1.parseCoverageContract)(input, 'coverage.json')).toThrow('path');
47
47
  });
48
- test.each(['.semgrep.awm.yml', '.dep-cruiser.awm.js'])('accepts safe dotfile evidence path %p', (path) => {
48
+ test.each([
49
+ 'eslint.config.awm.mjs',
50
+ 'eslint.config.js',
51
+ 'eslint.config.mjs',
52
+ 'eslint.config.cjs',
53
+ 'eslint.config.ts',
54
+ 'eslint.config.mts',
55
+ 'eslint.config.cts',
56
+ '.semgrep.awm.yml',
57
+ '.dep-cruiser.awm.js',
58
+ ])('accepts contractual evidence path %p', (path) => {
49
59
  const input = {
50
60
  schemaVersion: 1,
51
61
  classes: {
@@ -64,7 +74,7 @@ describe('coverage contract v1', () => {
64
74
  classes: {
65
75
  valid: {
66
76
  description: 'x',
67
- detectors: [{ sensor: 'test', evidence: { files: [{ path: 'report.txt', containsAll: [' \n'] }] } }],
77
+ detectors: [{ sensor: 'test', evidence: { files: [{ path: 'eslint.config.awm.mjs', containsAll: [' \n'] }] } }],
68
78
  remedy: { summary: 'x', command: 'x' },
69
79
  },
70
80
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentic-workflow-manager",
3
- "version": "6.5.1",
3
+ "version": "6.5.2",
4
4
  "main": "dist/src/index.js",
5
5
  "bin": {
6
6
  "awm": "./dist/src/index.js"