deployproof 0.1.5__tar.gz → 0.1.7__tar.gz

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.
Files changed (36) hide show
  1. {deployproof-0.1.5/src/deployproof.egg-info → deployproof-0.1.7}/PKG-INFO +29 -15
  2. {deployproof-0.1.5 → deployproof-0.1.7}/README.md +22 -9
  3. {deployproof-0.1.5 → deployproof-0.1.7}/pyproject.toml +16 -6
  4. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/__init__.py +1 -1
  5. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/dependencies.py +1 -1
  6. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/mocks.py +20 -5
  7. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/reporter.py +1 -1
  8. {deployproof-0.1.5 → deployproof-0.1.7/src/deployproof.egg-info}/PKG-INFO +29 -15
  9. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_cli.py +3 -3
  10. {deployproof-0.1.5 → deployproof-0.1.7}/LICENSE +0 -0
  11. {deployproof-0.1.5 → deployproof-0.1.7}/setup.cfg +0 -0
  12. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/cli.py +0 -0
  13. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/control_flow.py +0 -0
  14. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/diff.py +0 -0
  15. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/mutator.py +0 -0
  16. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/secrets.py +0 -0
  17. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/symlinks.py +0 -0
  18. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof/wsl.py +0 -0
  19. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof.egg-info/SOURCES.txt +0 -0
  20. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof.egg-info/dependency_links.txt +0 -0
  21. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof.egg-info/entry_points.txt +0 -0
  22. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof.egg-info/requires.txt +0 -0
  23. {deployproof-0.1.5 → deployproof-0.1.7}/src/deployproof.egg-info/top_level.txt +0 -0
  24. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_cli_dependency_scan.py +0 -0
  25. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_control_flow.py +0 -0
  26. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_dependencies_extractor.py +0 -0
  27. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_dependencies_pypi.py +0 -0
  28. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_diff.py +0 -0
  29. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_edge_cases_validation.py +0 -0
  30. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_mocks.py +0 -0
  31. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_mutation_suites.py +0 -0
  32. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_mutator.py +0 -0
  33. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_secrets.py +0 -0
  34. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_stress_regressions.py +0 -0
  35. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_symlinks.py +0 -0
  36. {deployproof-0.1.5 → deployproof-0.1.7}/tests/test_wsl.py +0 -0
@@ -1,13 +1,14 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: deployproof
3
- Version: 0.1.5
3
+ Version: 0.1.7
4
4
  Summary: A deterministic AI-code deployability checker that catches what coverage misses.
5
- Author: SVS Praveen
5
+ Author-email: SVS Praveen <svspraveens@gmail.com>
6
6
  License-Expression: MIT
7
- Project-URL: Homepage, https://github.com/SVSPraveen/deployproof
8
- Project-URL: Documentation, https://github.com/SVSPraveen/deployproof#readme
9
- Project-URL: Repository, https://github.com/SVSPraveen/deployproof.git
10
- Project-URL: Bug Tracker, https://github.com/SVSPraveen/deployproof/issues
7
+ Project-URL: Homepage, https://github.com/SVSPraveen/DeployProof
8
+ Project-URL: Documentation, https://github.com/SVSPraveen/DeployProof#readme
9
+ Project-URL: Repository, https://github.com/SVSPraveen/DeployProof.git
10
+ Project-URL: Bug Tracker, https://github.com/SVSPraveen/DeployProof/issues
11
+ Keywords: ai-code,mutation-testing,security-scanner,slopsquatting,ghostapproval,pre-push-verification,ast-analysis,dependency-security
11
12
  Classifier: Development Status :: 3 - Alpha
12
13
  Classifier: Intended Audience :: Developers
13
14
  Classifier: Programming Language :: Python :: 3
@@ -29,18 +30,18 @@ Dynamic: license-file
29
30
 
30
31
  # DeployProof
31
32
 
32
- > A pre-push verification tool for AI-assisted codebases: mutation testing, credential scanning, sandbox-escape detection, and dependency hallucination checks.
33
+ > Deterministic pre-push verification for AI-assisted codebases: AST mutation testing, credential scanning, sandbox-escape detection, mock-usage alerts, swallowed-exception checks, and dependency hallucination defense.
33
34
 
34
- [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
35
- [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
36
- [![Tests](https://img.shields.io/badge/tests-79%20passed-brightgreen.svg)](https://github.com/SVSPraveen/DeployProof)
35
+ [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=007ec6)](https://pypi.org/project/deployproof/)
36
+ [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=3776ab)](https://pypi.org/project/deployproof/)
37
+ [![Tests](https://img.shields.io/badge/tests-79%20passed-2ea44f.svg)](https://github.com/SVSPraveen/DeployProof)
37
38
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
38
39
 
39
40
  ---
40
41
 
41
42
  ## Why This Exists
42
43
 
43
- AI-assisted development introduces failure modes that standard tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
44
+ AI-assisted development introduces subtle failure modes that standard linters and coverage tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, silently swallowed exceptions, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
44
45
 
45
46
  ## Install
46
47
 
@@ -58,13 +59,26 @@ Initialize in your repository:
58
59
  deployproof init
59
60
  ```
60
61
 
61
- Run all verification checks against changes in the current session:
62
+ Run all verification checks against changes in the current session (git diff):
62
63
 
63
64
  ```bash
64
65
  deployproof check
65
66
  ```
66
67
 
67
- Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push. Supports `--json` for machine-readable output and `--strict-mocks` / `--strict-error-handling` to turn informational checks into hard verification gates.
68
+ Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push.
69
+
70
+ ### CLI Options & Flags
71
+
72
+ | Flag | Description |
73
+ |---|---|
74
+ | `deployproof check` | Run all 6 pre-push verification checks (informational warnings for mocks and error handling). |
75
+ | `deployproof check --json` | Output structured, machine-readable JSON for CI/CD pipelines, IDEs, and automation. |
76
+ | `deployproof check --strict-mocks` | Fail the gate (exit code 1) if new `unittest.mock`, `mocker`, or `monkeypatch` usage is introduced. |
77
+ | `deployproof check --strict-error-handling` | Fail the gate (exit code 1) if bare excepts, swallowed exceptions, or dead code are detected. |
78
+ | `deployproof check --files <paths...>` | Explicitly evaluate specific files (bypasses git diff). |
79
+ | `deployproof check --threshold <float>` | Minimum mutation score percentage required to pass (default: `80.0`). |
80
+ | `deployproof check --base <ref>` | Base git ref (branch/commit/tag) to diff against. |
81
+ | `deployproof check --wsl` | Delegate mutation testing to `mutmut` inside WSL (Windows only). |
68
82
 
69
83
  ### Machine-Readable Output (`--json`)
70
84
 
@@ -78,7 +92,7 @@ deployproof check --json
78
92
 
79
93
  ```json
80
94
  {
81
- "version": "0.1.5",
95
+ "version": "0.1.7",
82
96
  "status": "passed",
83
97
  "summary": {
84
98
  "target_files_count": 1,
@@ -177,7 +191,7 @@ Fixtures cover weak test suites, zero-test orphan modules, planted OpenAI/AWS cr
177
191
 
178
192
  ## Status & Roadmap
179
193
 
180
- - **Current (v0.1.5):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks`), control-flow / swallowed-exception scanner (`--strict-error-handling`), machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
194
+ - **Current (v0.1.7):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks` and deduplicated decorator detection), control-flow / swallowed-exception scanner (`--strict-error-handling`), 11/11 launch-day stress test suite, machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
181
195
  - **Next:** Multi-language mutation support and expanded ecosystem rule packs.
182
196
 
183
197
  ## Contributing
@@ -1,17 +1,17 @@
1
1
  # DeployProof
2
2
 
3
- > A pre-push verification tool for AI-assisted codebases: mutation testing, credential scanning, sandbox-escape detection, and dependency hallucination checks.
3
+ > Deterministic pre-push verification for AI-assisted codebases: AST mutation testing, credential scanning, sandbox-escape detection, mock-usage alerts, swallowed-exception checks, and dependency hallucination defense.
4
4
 
5
- [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
6
- [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
7
- [![Tests](https://img.shields.io/badge/tests-79%20passed-brightgreen.svg)](https://github.com/SVSPraveen/DeployProof)
5
+ [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=007ec6)](https://pypi.org/project/deployproof/)
6
+ [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=3776ab)](https://pypi.org/project/deployproof/)
7
+ [![Tests](https://img.shields.io/badge/tests-79%20passed-2ea44f.svg)](https://github.com/SVSPraveen/DeployProof)
8
8
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
9
9
 
10
10
  ---
11
11
 
12
12
  ## Why This Exists
13
13
 
14
- AI-assisted development introduces failure modes that standard tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
14
+ AI-assisted development introduces subtle failure modes that standard linters and coverage tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, silently swallowed exceptions, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
15
15
 
16
16
  ## Install
17
17
 
@@ -29,13 +29,26 @@ Initialize in your repository:
29
29
  deployproof init
30
30
  ```
31
31
 
32
- Run all verification checks against changes in the current session:
32
+ Run all verification checks against changes in the current session (git diff):
33
33
 
34
34
  ```bash
35
35
  deployproof check
36
36
  ```
37
37
 
38
- Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push. Supports `--json` for machine-readable output and `--strict-mocks` / `--strict-error-handling` to turn informational checks into hard verification gates.
38
+ Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push.
39
+
40
+ ### CLI Options & Flags
41
+
42
+ | Flag | Description |
43
+ |---|---|
44
+ | `deployproof check` | Run all 6 pre-push verification checks (informational warnings for mocks and error handling). |
45
+ | `deployproof check --json` | Output structured, machine-readable JSON for CI/CD pipelines, IDEs, and automation. |
46
+ | `deployproof check --strict-mocks` | Fail the gate (exit code 1) if new `unittest.mock`, `mocker`, or `monkeypatch` usage is introduced. |
47
+ | `deployproof check --strict-error-handling` | Fail the gate (exit code 1) if bare excepts, swallowed exceptions, or dead code are detected. |
48
+ | `deployproof check --files <paths...>` | Explicitly evaluate specific files (bypasses git diff). |
49
+ | `deployproof check --threshold <float>` | Minimum mutation score percentage required to pass (default: `80.0`). |
50
+ | `deployproof check --base <ref>` | Base git ref (branch/commit/tag) to diff against. |
51
+ | `deployproof check --wsl` | Delegate mutation testing to `mutmut` inside WSL (Windows only). |
39
52
 
40
53
  ### Machine-Readable Output (`--json`)
41
54
 
@@ -49,7 +62,7 @@ deployproof check --json
49
62
 
50
63
  ```json
51
64
  {
52
- "version": "0.1.5",
65
+ "version": "0.1.7",
53
66
  "status": "passed",
54
67
  "summary": {
55
68
  "target_files_count": 1,
@@ -148,7 +161,7 @@ Fixtures cover weak test suites, zero-test orphan modules, planted OpenAI/AWS cr
148
161
 
149
162
  ## Status & Roadmap
150
163
 
151
- - **Current (v0.1.5):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks`), control-flow / swallowed-exception scanner (`--strict-error-handling`), machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
164
+ - **Current (v0.1.7):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks` and deduplicated decorator detection), control-flow / swallowed-exception scanner (`--strict-error-handling`), 11/11 launch-day stress test suite, machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
152
165
  - **Next:** Multi-language mutation support and expanded ecosystem rule packs.
153
166
 
154
167
  ## Contributing
@@ -4,13 +4,23 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "deployproof"
7
- version = "0.1.5"
7
+ version = "0.1.7"
8
8
  description = "A deterministic AI-code deployability checker that catches what coverage misses."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
11
11
  license = "MIT"
12
12
  authors = [
13
- { name = "SVS Praveen" }
13
+ { name = "SVS Praveen", email = "svspraveens@gmail.com" }
14
+ ]
15
+ keywords = [
16
+ "ai-code",
17
+ "mutation-testing",
18
+ "security-scanner",
19
+ "slopsquatting",
20
+ "ghostapproval",
21
+ "pre-push-verification",
22
+ "ast-analysis",
23
+ "dependency-security",
14
24
  ]
15
25
  classifiers = [
16
26
  "Development Status :: 3 - Alpha",
@@ -34,10 +44,10 @@ dev = [
34
44
  ]
35
45
 
36
46
  [project.urls]
37
- Homepage = "https://github.com/SVSPraveen/deployproof"
38
- Documentation = "https://github.com/SVSPraveen/deployproof#readme"
39
- Repository = "https://github.com/SVSPraveen/deployproof.git"
40
- "Bug Tracker" = "https://github.com/SVSPraveen/deployproof/issues"
47
+ Homepage = "https://github.com/SVSPraveen/DeployProof"
48
+ Documentation = "https://github.com/SVSPraveen/DeployProof#readme"
49
+ Repository = "https://github.com/SVSPraveen/DeployProof.git"
50
+ "Bug Tracker" = "https://github.com/SVSPraveen/DeployProof/issues"
41
51
 
42
52
  [project.scripts]
43
53
  deployproof = "deployproof.cli:main"
@@ -1,2 +1,2 @@
1
1
  """DeployProof: Deterministic deployability verification for AI-assisted code."""
2
- __version__ = "0.1.5"
2
+ __version__ = "0.1.7"
@@ -891,7 +891,7 @@ def query_pypi_registry(
891
891
  url = f"https://pypi.org/pypi/{norm_name}/json"
892
892
  req = urllib.request.Request(
893
893
  url,
894
- headers={"User-Agent": "DeployProof/0.1.5 (https://github.com/SVSPraveen/DeployProof)"},
894
+ headers={"User-Agent": "DeployProof/0.1.7 (https://github.com/SVSPraveen/DeployProof)"},
895
895
  )
896
896
 
897
897
  try:
@@ -43,6 +43,7 @@ class MockDetector(ast.NodeVisitor):
43
43
  self.modified_lines = modified_lines
44
44
  self.findings: List[MockFinding] = []
45
45
  self._seen_lines_and_types: Set[Tuple[int, str]] = set()
46
+ self._decorator_call_nodes: Set[int] = set()
46
47
 
47
48
  def _add_finding(self, lineno: int, mock_type: str, description: str) -> None:
48
49
  if self.modified_lines is not None and lineno not in self.modified_lines:
@@ -105,6 +106,19 @@ class MockDetector(ast.NodeVisitor):
105
106
  )
106
107
  self.generic_visit(node)
107
108
 
109
+ def _check_decorators(self, node: ast.AST) -> None:
110
+ decorators = getattr(node, "decorator_list", [])
111
+ for dec in decorators:
112
+ if isinstance(dec, ast.Call):
113
+ self._decorator_call_nodes.add(id(dec))
114
+ if self._is_patch_target_node(dec):
115
+ lineno = getattr(dec, "lineno", getattr(node, "lineno", 1))
116
+ self._add_finding(lineno, "patch_decorator", "@patch decorator")
117
+
118
+ def visit_ClassDef(self, node: ast.ClassDef) -> None:
119
+ self._check_decorators(node)
120
+ self.generic_visit(node)
121
+
108
122
  def visit_FunctionDef(self, node: ast.FunctionDef) -> None:
109
123
  self._check_func(node)
110
124
  self.generic_visit(node)
@@ -126,11 +140,7 @@ class MockDetector(ast.NodeVisitor):
126
140
  f"{arg.arg} fixture parameter in {getattr(node, 'name', 'function')}()",
127
141
  )
128
142
 
129
- decorators = getattr(node, "decorator_list", [])
130
- for dec in decorators:
131
- if self._is_patch_target_node(dec):
132
- lineno = getattr(dec, "lineno", getattr(node, "lineno", 1))
133
- self._add_finding(lineno, "patch_decorator", "@patch decorator")
143
+ self._check_decorators(node)
134
144
 
135
145
  def _is_patch_target_node(self, node: ast.AST) -> bool:
136
146
  if isinstance(node, ast.Call):
@@ -152,6 +162,11 @@ class MockDetector(ast.NodeVisitor):
152
162
  return False
153
163
 
154
164
  def visit_Call(self, node: ast.Call) -> None:
165
+ # If this call is an @patch decorator call, it is already recorded as patch_decorator
166
+ if id(node) in self._decorator_call_nodes:
167
+ self.generic_visit(node)
168
+ return
169
+
155
170
  if isinstance(node.func, ast.Attribute):
156
171
  if isinstance(node.func.value, ast.Name) and node.func.value.id == "monkeypatch":
157
172
  self._add_finding(
@@ -26,7 +26,7 @@ def format_json_report(
26
26
  strict_error_handling: bool = False,
27
27
  repo_root: Optional[Path] = None,
28
28
  threshold: float = 80.0,
29
- version: str = "0.1.5",
29
+ version: str = "0.1.7",
30
30
  ) -> str:
31
31
  """Format all scan findings and mutation results as a structured JSON string."""
32
32
  root = (repo_root or Path.cwd()).resolve()
@@ -1,13 +1,14 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: deployproof
3
- Version: 0.1.5
3
+ Version: 0.1.7
4
4
  Summary: A deterministic AI-code deployability checker that catches what coverage misses.
5
- Author: SVS Praveen
5
+ Author-email: SVS Praveen <svspraveens@gmail.com>
6
6
  License-Expression: MIT
7
- Project-URL: Homepage, https://github.com/SVSPraveen/deployproof
8
- Project-URL: Documentation, https://github.com/SVSPraveen/deployproof#readme
9
- Project-URL: Repository, https://github.com/SVSPraveen/deployproof.git
10
- Project-URL: Bug Tracker, https://github.com/SVSPraveen/deployproof/issues
7
+ Project-URL: Homepage, https://github.com/SVSPraveen/DeployProof
8
+ Project-URL: Documentation, https://github.com/SVSPraveen/DeployProof#readme
9
+ Project-URL: Repository, https://github.com/SVSPraveen/DeployProof.git
10
+ Project-URL: Bug Tracker, https://github.com/SVSPraveen/DeployProof/issues
11
+ Keywords: ai-code,mutation-testing,security-scanner,slopsquatting,ghostapproval,pre-push-verification,ast-analysis,dependency-security
11
12
  Classifier: Development Status :: 3 - Alpha
12
13
  Classifier: Intended Audience :: Developers
13
14
  Classifier: Programming Language :: Python :: 3
@@ -29,18 +30,18 @@ Dynamic: license-file
29
30
 
30
31
  # DeployProof
31
32
 
32
- > A pre-push verification tool for AI-assisted codebases: mutation testing, credential scanning, sandbox-escape detection, and dependency hallucination checks.
33
+ > Deterministic pre-push verification for AI-assisted codebases: AST mutation testing, credential scanning, sandbox-escape detection, mock-usage alerts, swallowed-exception checks, and dependency hallucination defense.
33
34
 
34
- [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
35
- [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=blue)](https://pypi.org/project/deployproof/)
36
- [![Tests](https://img.shields.io/badge/tests-79%20passed-brightgreen.svg)](https://github.com/SVSPraveen/DeployProof)
35
+ [![PyPI version](https://img.shields.io/pypi/v/deployproof.svg?color=007ec6)](https://pypi.org/project/deployproof/)
36
+ [![Python versions](https://img.shields.io/pypi/pyversions/deployproof.svg?color=3776ab)](https://pypi.org/project/deployproof/)
37
+ [![Tests](https://img.shields.io/badge/tests-79%20passed-2ea44f.svg)](https://github.com/SVSPraveen/DeployProof)
37
38
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
38
39
 
39
40
  ---
40
41
 
41
42
  ## Why This Exists
42
43
 
43
- AI-assisted development introduces failure modes that standard tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
44
+ AI-assisted development introduces subtle failure modes that standard linters and coverage tools miss: test suites with high line coverage but near-zero mutation scores, hardcoded credentials generated in passing, symlinks that deceive approval prompts into escaping the repository sandbox, silently swallowed exceptions, and package names hallucinated by LLMs that don't exist on PyPI. DeployProof catches these at the pre-push stage, before they reach CI or production.
44
45
 
45
46
  ## Install
46
47
 
@@ -58,13 +59,26 @@ Initialize in your repository:
58
59
  deployproof init
59
60
  ```
60
61
 
61
- Run all verification checks against changes in the current session:
62
+ Run all verification checks against changes in the current session (git diff):
62
63
 
63
64
  ```bash
64
65
  deployproof check
65
66
  ```
66
67
 
67
- Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push. Supports `--json` for machine-readable output and `--strict-mocks` / `--strict-error-handling` to turn informational checks into hard verification gates.
68
+ Output includes a section for each check — symlink scan, secrets scan, dependency scan, mock detection, control flow analysis, and mutation score — with a pass/fail line at the bottom. Exit code is non-zero on any finding that should block a push.
69
+
70
+ ### CLI Options & Flags
71
+
72
+ | Flag | Description |
73
+ |---|---|
74
+ | `deployproof check` | Run all 6 pre-push verification checks (informational warnings for mocks and error handling). |
75
+ | `deployproof check --json` | Output structured, machine-readable JSON for CI/CD pipelines, IDEs, and automation. |
76
+ | `deployproof check --strict-mocks` | Fail the gate (exit code 1) if new `unittest.mock`, `mocker`, or `monkeypatch` usage is introduced. |
77
+ | `deployproof check --strict-error-handling` | Fail the gate (exit code 1) if bare excepts, swallowed exceptions, or dead code are detected. |
78
+ | `deployproof check --files <paths...>` | Explicitly evaluate specific files (bypasses git diff). |
79
+ | `deployproof check --threshold <float>` | Minimum mutation score percentage required to pass (default: `80.0`). |
80
+ | `deployproof check --base <ref>` | Base git ref (branch/commit/tag) to diff against. |
81
+ | `deployproof check --wsl` | Delegate mutation testing to `mutmut` inside WSL (Windows only). |
68
82
 
69
83
  ### Machine-Readable Output (`--json`)
70
84
 
@@ -78,7 +92,7 @@ deployproof check --json
78
92
 
79
93
  ```json
80
94
  {
81
- "version": "0.1.5",
95
+ "version": "0.1.7",
82
96
  "status": "passed",
83
97
  "summary": {
84
98
  "target_files_count": 1,
@@ -177,7 +191,7 @@ Fixtures cover weak test suites, zero-test orphan modules, planted OpenAI/AWS cr
177
191
 
178
192
  ## Status & Roadmap
179
193
 
180
- - **Current (v0.1.5):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks`), control-flow / swallowed-exception scanner (`--strict-error-handling`), machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
194
+ - **Current (v0.1.7):** Diff-scoped AST mutation testing, secrets scanner (including unquoted .env values), GhostApproval symlink sandbox-escape detector, PyPI dependency hallucination / slopsquatting scanner (with recursive `-r` requirements scanning and dynamic import detection via `importlib` / `__import__`), mock-introduction detector (`--strict-mocks` and deduplicated decorator detection), control-flow / swallowed-exception scanner (`--strict-error-handling`), 11/11 launch-day stress test suite, machine-readable `--json` output, and Tier 2 CI verification via GitHub Actions (mutmut).
181
195
  - **Next:** Multi-language mutation support and expanded ecosystem rule packs.
182
196
 
183
197
  ## Contributing
@@ -9,7 +9,7 @@ from deployproof.cli import create_parser, main
9
9
 
10
10
  def test_version():
11
11
  """Verify version string is accessible."""
12
- assert __version__ == "0.1.5"
12
+ assert __version__ == "0.1.7"
13
13
 
14
14
 
15
15
  def test_parser_version(capsys):
@@ -19,7 +19,7 @@ def test_parser_version(capsys):
19
19
  parser.parse_args(["--version"])
20
20
  assert exc_info.value.code == 0
21
21
  captured = capsys.readouterr()
22
- assert "deployproof 0.1.5" in captured.out or "deployproof 0.1.5" in captured.err
22
+ assert "deployproof 0.1.7" in captured.out or "deployproof 0.1.7" in captured.err
23
23
 
24
24
 
25
25
  def test_parser_help(capsys):
@@ -105,7 +105,7 @@ def test_main_check_json_output_passing(capsys):
105
105
 
106
106
  data = json.loads(captured.out)
107
107
  assert data["status"] == "passed"
108
- assert data["version"] == "0.1.5"
108
+ assert data["version"] == "0.1.7"
109
109
  assert data["summary"]["mutation_score"] == 100.0
110
110
  assert data["summary"]["secrets_found"] == 0
111
111
  assert data["summary"]["symlink_escapes_found"] == 0
File without changes
File without changes