quality-graph-python 0.1.2__py3-none-any.whl → 0.1.6__py3-none-any.whl

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.
@@ -0,0 +1,98 @@
1
+ Metadata-Version: 2.4
2
+ Name: quality-graph-python
3
+ Version: 0.1.6
4
+ Summary: Reusable Python quality gates for Quality Graph
5
+ Project-URL: Homepage, https://alchemmist.github.io/quality-graph/
6
+ Project-URL: Documentation, https://alchemmist.github.io/quality-graph/
7
+ License-Expression: MIT
8
+ Requires-Python: >=3.12
9
+ Requires-Dist: anyio>=4.11.0
10
+ Description-Content-Type: text/markdown
11
+
12
+ # Quality Graph Python Gates
13
+
14
+ Provider-independent source and diff quality gates for Python repositories. The package does not
15
+ depend on the GitHub provider and every command can run locally, in Quality Graph, or in another
16
+ CI system.
17
+
18
+ ## Installation
19
+
20
+ ```bash
21
+ uv add --dev quality-graph-python==0.1.2
22
+ ```
23
+
24
+ Diff-based commands compare committed repository content with `origin/main` by default. CI must
25
+ fetch the base history. Pass `--base` when the default branch or comparison point differs.
26
+
27
+ ## Commands
28
+
29
+ | Command | Scope | What fails |
30
+ | --- | --- | --- |
31
+ | `qg-python-suppressions --base origin/main` | Added lines in Python and common config files | New `noqa`, `nosec`, type ignores, coverage pragmas, or ignore/exclude configuration |
32
+ | `qg-python-object-annotations --base origin/main` | Added Python annotation lines | Direct, qualified, or forward `object` annotations |
33
+ | `qg-python-triple-quotes --base origin/main` | Added Python string delimiters | One-line triple-quoted strings or multiline delimiters sharing a line with content; real docstrings are excluded |
34
+ | `qg-python-time-bombs --base origin/main` | Added Python and shell lines | Integer literals that plausibly encode Unix timestamps in seconds through nanoseconds |
35
+ | `qg-python-no-comments packages apps scripts` | Every Python file below the selected roots | Code comments other than shebangs and narrowly recognized tool directives |
36
+ | `qg-python-flaky --base origin/main --attempts 3` | Changed Python test files | Consistent failures or mixed pass/fail outcomes across repeated pytest runs |
37
+
38
+ Diagnostics use `path:line:column: message` and commands return non-zero when findings exist.
39
+
40
+ ## Make integration
41
+
42
+ Keep graph nodes semantic by routing commands through repository Make targets:
43
+
44
+ ```makefile
45
+ BASE ?= origin/main
46
+
47
+ .PHONY: python-suppressions python-object-annotations python-triple-quotes \
48
+ python-time-bombs python-no-comments flaky-python
49
+
50
+ python-suppressions:
51
+ uv run qg-python-suppressions --base "$(BASE)"
52
+
53
+ python-object-annotations:
54
+ uv run qg-python-object-annotations --base "$(BASE)"
55
+
56
+ python-triple-quotes:
57
+ uv run qg-python-triple-quotes --base "$(BASE)"
58
+
59
+ python-time-bombs:
60
+ uv run qg-python-time-bombs --base "$(BASE)"
61
+
62
+ python-no-comments:
63
+ uv run qg-python-no-comments packages apps scripts
64
+
65
+ flaky-python:
66
+ uv run qg-python-flaky --base "$(BASE)" --attempts 3
67
+ ```
68
+
69
+ The no-comments gate intentionally scans complete roots. The other source gates are incremental
70
+ and reject newly introduced debt without forcing an immediate cleanup of unchanged legacy code.
71
+
72
+ ## Graph integration
73
+
74
+ ```yaml
75
+ profiles:
76
+ python:
77
+ extends: default
78
+ setup:
79
+ - uses: astral-sh/setup-uv@v7
80
+ - run: uv sync --locked
81
+
82
+ nodes:
83
+ suppressions:
84
+ profile: python
85
+ run: make python-suppressions
86
+
87
+ type:
88
+ profile: python
89
+ needs: [suppressions]
90
+ run: make type
91
+
92
+ flaky:
93
+ profile: python
94
+ needs: [type]
95
+ run: make flaky-python
96
+ ```
97
+
98
+ Use `fetch-depth: "0"` on the checkout setup step when any node compares against a Git base.
@@ -8,7 +8,7 @@ qg_python/report.py,sha256=t5zIYuCxy-WPgtNHXETKDLHTkzqkEw8jUFiGaYOwSEs,763
8
8
  qg_python/suppressions.py,sha256=i9HL8-OsU_cS1mTZTw19Y90uttmWWwLkVa1MEEeJf3E,1753
9
9
  qg_python/time_bombs.py,sha256=rwiACRITy4w8cRnD1W6lY7w0plExF8hXJCA-EXZs-Gg,2011
10
10
  qg_python/triple_quotes.py,sha256=aLWGlIsOjXNeLxDsRjJz3ifedY8tamGot9ywsXZa4Pg,5281
11
- quality_graph_python-0.1.2.dist-info/METADATA,sha256=gNtsQzKNGoRlG_qzEDX1G3lKCU4lHpqUsL19DtxExpY,345
12
- quality_graph_python-0.1.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
13
- quality_graph_python-0.1.2.dist-info/entry_points.txt,sha256=1n7ymDB-MgzrAF8Rw0hnB2VClnA8mfLjT-BMAAboW-s,330
14
- quality_graph_python-0.1.2.dist-info/RECORD,,
11
+ quality_graph_python-0.1.6.dist-info/METADATA,sha256=UOuFxnxmcvtcO5i13h0jqQ2Y1NKe5CY3sSkFDe4btG8,3415
12
+ quality_graph_python-0.1.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
13
+ quality_graph_python-0.1.6.dist-info/entry_points.txt,sha256=1n7ymDB-MgzrAF8Rw0hnB2VClnA8mfLjT-BMAAboW-s,330
14
+ quality_graph_python-0.1.6.dist-info/RECORD,,
@@ -1,12 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: quality-graph-python
3
- Version: 0.1.2
4
- Summary: Reusable Python quality gates for Quality Graph
5
- License-Expression: MIT
6
- Requires-Python: >=3.12
7
- Requires-Dist: anyio>=4.11.0
8
- Description-Content-Type: text/markdown
9
-
10
- # Quality Graph Python Gates
11
-
12
- Provider-independent source and diff quality gates for Python repositories.