Skip to content

Commit 05ffa8c

Browse files
chore: lighter issue + PR templates — strip required fields, drop ADR, allow blank issues (#59)
* chore(issue-templates): remove ADR template (too heavy; ADR label + free-form issue is enough) * chore(issue-templates): slim bug_report to title + one description field * chore(issue-templates): slim feature_request to title + one description field * chore(issue-templates): slim rule-request to title + one description field * chore(issue-templates): enable blank issues for contributors who skip the template * chore(pr-template): collapse to a free-form 'What changed' section
1 parent d8f6c0f commit 05ffa8c

6 files changed

Lines changed: 34 additions & 319 deletions

File tree

.github/ISSUE_TEMPLATE/adr.yml

Lines changed: 0 additions & 111 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 15 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -6,64 +6,20 @@ body:
66
- type: markdown
77
attributes:
88
value: |
9-
Thanks for reporting a bug. If this is a **security**
10-
issue (rule bypass, false negative on a dangerous SQL
11-
pattern), please file a [private advisory](../../security/advisories/new)
12-
instead of a public issue.
13-
14-
- type: input
15-
id: version
16-
attributes:
17-
label: sql-sop version
18-
description: Output of `sql-sop --version`
19-
placeholder: e.g. 0.4.0
20-
validations:
21-
required: true
22-
23-
- type: input
24-
id: python
25-
attributes:
26-
label: Python version
27-
placeholder: e.g. 3.11.9
28-
validations:
29-
required: true
30-
31-
- type: input
32-
id: os
33-
attributes:
34-
label: Operating system
35-
placeholder: e.g. Ubuntu 24.04, Windows 11, macOS 14
36-
validations:
37-
required: true
38-
39-
- type: textarea
40-
id: sql
41-
attributes:
42-
label: SQL that reproduces the problem
43-
description: Paste the SQL string or point at a fixture file.
44-
render: sql
45-
validations:
46-
required: true
47-
48-
- type: textarea
49-
id: expected
50-
attributes:
51-
label: Expected behaviour
52-
description: Which rule (E001, W001, ...) should have fired, or not fired?
53-
validations:
54-
required: true
9+
For **security** issues (rule bypass, false negative on a dangerous
10+
SQL pattern), please file a
11+
[private advisory](../../security/advisories/new) instead of a
12+
public issue.
5513
5614
- type: textarea
57-
id: actual
58-
attributes:
59-
label: Actual behaviour
60-
description: What sql-sop actually reported. Paste the CLI output.
61-
render: shell
62-
validations:
63-
required: true
64-
65-
- type: textarea
66-
id: extras
67-
attributes:
68-
label: Additional context
69-
description: Anything else that would help — pre-commit config, CI workflow step, environment variables.
15+
id: description
16+
attributes:
17+
label: What's wrong?
18+
description: |
19+
Anything that helps us understand and reproduce. Skip anything
20+
that isn't relevant.
21+
placeholder: |
22+
sql-sop version + Python version (if relevant)
23+
What you ran
24+
What you expected
25+
What actually happened

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,11 @@
1-
blank_issues_enabled: false
1+
blank_issues_enabled: true
22
contact_links:
33
- name: Security report (rule bypass, false negative, CVE)
44
url: https://github.com/Pawansingh3889/sql-guard/security/advisories/new
55
about: Security issues go through the private advisory channel, not a public issue. See SECURITY.md.
66
- name: "Usage question - 'how do I...?'"
77
url: https://github.com/Pawansingh3889/sql-guard/discussions/categories/q-a
88
about: Ask in Discussions - lower friction than an issue, often a faster reply.
9-
- name: "Show us how you're using sql-sop"
10-
url: https://github.com/Pawansingh3889/sql-guard/discussions/categories/show-and-tell
11-
about: Share your use case - we feature replies in the README.
129
- name: General discussion / open-ended question
1310
url: https://github.com/Pawansingh3889/sql-guard/discussions
1411
about: Anything that isn't a bug, rule request, or feature proposal.
Lines changed: 6 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,12 @@
11
name: Feature request
2-
description: Suggest a new rule, rule change, or improvement
2+
description: Suggest a new rule, change, or improvement
33
title: "[Feature]: "
44
labels: ["enhancement"]
55
body:
6-
- type: markdown
7-
attributes:
8-
value: |
9-
Thanks for suggesting. If you're proposing a **new rule**,
10-
see `CONTRIBUTING.md` § "Adding a new rule" for the shape
11-
of the work.
12-
13-
- type: textarea
14-
id: problem
15-
attributes:
16-
label: What problem does this solve?
17-
description: Describe the SQL hazard or developer pain. Examples of the pattern in real code are gold.
18-
validations:
19-
required: true
20-
21-
- type: textarea
22-
id: proposal
23-
attributes:
24-
label: Proposed change
25-
description: New rule ID (next unused E00N / W0NN / S00N / P00N), name, severity, and a one-sentence description.
26-
validations:
27-
required: true
28-
29-
- type: textarea
30-
id: examples
31-
attributes:
32-
label: Examples
33-
description: SQL that should fire the rule, and SQL that should NOT (so the false-positive risk is visible).
34-
render: sql
35-
366
- type: textarea
37-
id: alternatives
38-
attributes:
39-
label: Alternatives considered
40-
description: Why this over existing rules, or over "just educate developers"?
41-
42-
- type: checkboxes
43-
id: breaking
7+
id: description
448
attributes:
45-
label: Breaking-change check
46-
description: Rule removal, ID renaming, or default-severity changes break downstream pre-commit configs.
47-
options:
48-
- label: This change does NOT remove or rename any existing rule ID or change a default severity.
9+
label: What would you like to see?
10+
description: |
11+
Freeform. Describe the problem, the proposal, and any examples
12+
that help. Don't fuss about structure — we'll ask if we need more.
Lines changed: 10 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,80 +1,18 @@
11
name: Rule request
22
description: Suggest a new SQL or Python lint rule
3-
title: "rule: <one-line description>"
3+
title: "rule: "
44
labels: ["rule-request", "needs-triage"]
55
body:
6-
- type: markdown
7-
attributes:
8-
value: |
9-
Thanks for helping sharpen sql-sop. One rule-per-issue, please.
10-
If you're not sure whether it fits, open it anyway - triage is fast.
11-
126
- type: textarea
13-
id: what
7+
id: description
148
attributes:
159
label: What pattern should this rule catch?
16-
description: One sentence. Example - "Warn on UNION when UNION ALL would work."
17-
placeholder: "Warn on ..."
18-
validations:
19-
required: true
20-
21-
- type: textarea
22-
id: fail-example
23-
attributes:
24-
label: SQL (or Python) example that should fail
25-
description: Paste minimal code that should trigger the new rule.
26-
render: sql
27-
placeholder: |
28-
SELECT id FROM orders
29-
UNION
30-
SELECT id FROM archived_orders;
31-
validations:
32-
required: true
33-
34-
- type: textarea
35-
id: pass-example
36-
attributes:
37-
label: SQL (or Python) example that should NOT trigger
38-
description: The boundary case - helps us avoid false positives.
39-
render: sql
10+
description: |
11+
Useful to include if you have them — a SQL example that should
12+
fail, an example that should pass, why this matters in
13+
production. Skip what you don't have.
4014
placeholder: |
41-
SELECT id FROM orders
42-
UNION ALL
43-
SELECT id FROM archived_orders;
44-
validations:
45-
required: true
46-
47-
- type: dropdown
48-
id: severity
49-
attributes:
50-
label: Proposed severity
51-
options:
52-
- warning (advisory, doesn't block commits)
53-
- error (blocks commits / CI)
54-
- not sure
55-
default: 0
56-
validations:
57-
required: true
58-
59-
- type: input
60-
id: similar
61-
attributes:
62-
label: Similar existing rule (if any)
63-
description: Which rule ID would you model this on? Helps reviewers.
64-
placeholder: "e.g. W003 function-on-column"
65-
66-
- type: textarea
67-
id: why
68-
attributes:
69-
label: Why does this matter in production?
70-
description: A real bug you caught, a code review pattern, a DB outage, etc.
71-
72-
- type: checkboxes
73-
id: scope
74-
attributes:
75-
label: Scope checks (tick what applies)
76-
options:
77-
- label: This is a SQL pattern (regex-based rule in `sql_guard/rules/`)
78-
- label: This needs AST parsing (structural rule, sqlparse-based)
79-
- label: This is a Python scanner rule (libCST, in `sql_guard/rules/python_rules.py`)
80-
- label: I'm willing to open a PR for this myself
15+
Pattern:
16+
Example that should fail:
17+
Example that should pass:
18+
Why it matters:

.github/pull_request_template.md

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,6 @@
11
<!--
2-
Thanks for contributing to sql-sop! Fill out the sections below so the
3-
maintainer doesn't have to ask. One-line docs fixes can skip most
4-
sections; rule additions should fill everything.
2+
A brief description is enough. Skip anything that doesn't apply.
3+
Conventional Commit style for the title (feat: / fix: / docs: / chore: / ci: / test:) helps Release Please.
54
-->
65

76
## What changed
8-
9-
<!-- One or two sentences explaining the *why*, not just the *what*. -->
10-
11-
## Related issue
12-
13-
<!-- "Closes #123" or "Relates to #123". -->
14-
15-
## If this adds or changes a rule
16-
17-
- [ ] Rule ID is the next unused one in its family (`E00N` / `W0NN` / `S00N` / `P00N`)
18-
- [ ] Rule class registered in `sql_guard/rules/__init__.py`
19-
- [ ] Fixture line in `tests/fixtures/errors.sql` or `warnings.sql`
20-
- [ ] "Fires on bad SQL" test in `tests/test_rules.py`
21-
- [ ] "Does NOT fire on safe SQL" test (using `tmp_path`)
22-
- [ ] README rule table + Key Numbers count updated
23-
- [ ] Rule is not a removal or rename of an existing rule (breaking change — see `GOVERNANCE.md`)
24-
25-
## Tests
26-
27-
- [ ] `pytest -q` passes
28-
- [ ] `ruff check .` passes
29-
30-
## Checklist
31-
32-
- [ ] One logical change per commit, conventional commit style (`feat:`, `fix:`, `docs:`, `chore:`, `ci:`, `test:`, `style:`)
33-
- [ ] `CHANGELOG.md` `[Unreleased]` entry if user-facing
34-
35-
## Anything else reviewers should know

0 commit comments

Comments
 (0)