Skip to content

Commit b7da97d

Browse files
committed
.spec-driver
1 parent 343473f commit b7da97d

21 files changed

Lines changed: 260 additions & 182 deletions

File tree

.contracts/all/supekku/cli/list.py.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@ The --regexp flag does pattern matching on ID and title fields.
5959
The --filter flag does substring matching (case-insensitive).
6060
The --regexp flag does pattern matching on ID, slug, and name fields.
6161

62-
- @app.command(deltas) `list_deltas(root, ids, status, implements, substring, spec_filter, related_to, relation, referenced_by, not_referenced_by, unaudited, refs, tag, regexp, case_insensitive, format_type, json_output, truncate, details, external) -> None`: List deltas with optional filtering and status grouping.
62+
- @app.command(deltas) `list_deltas(root, ids, status, implements, substring, spec_filter, related_to, relation, referenced_by, not_referenced_by, unaudited, refs, tag, regexp, case_insensitive, format_type, json_output, truncate, details, external, show_all) -> None`: List deltas with optional filtering and status grouping.
63+
64+
By default, completed deltas are hidden. Use --all to show them.
6365

6466
The --filter flag does substring matching (case-insensitive).
6567
The --regexp flag filters on ID, name, and slug fields.
@@ -71,6 +73,8 @@ The --referenced-by/--not-referenced-by flags filter by reverse references.
7173
The --unaudited flag is sugar for --not-referenced-by audit -s completed.
7274

7375
Examples:
76+
list deltas # Shows active deltas (hides completed)
77+
list deltas --all # Shows all deltas
7478
list deltas -s draft,in-progress # Multi-value status filter
7579
list deltas --implements PROD-010.FR-004 # Reverse relationship query
7680
list deltas --spec PROD-010 # Deltas touching a spec

.contracts/public/supekku/cli/list.py.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ The --regexp flag does pattern matching on ID and title fields.
5252
The --filter flag does substring matching (case-insensitive).
5353
The --regexp flag does pattern matching on ID, slug, and name fields.
5454

55-
- @app.command(deltas) `list_deltas(root, ids, status, implements, substring, spec_filter, related_to, relation, referenced_by, not_referenced_by, unaudited, refs, tag, regexp, case_insensitive, format_type, json_output, truncate, details, external) -> None`: List deltas with optional filtering and status grouping.
55+
- @app.command(deltas) `list_deltas(root, ids, status, implements, substring, spec_filter, related_to, relation, referenced_by, not_referenced_by, unaudited, refs, tag, regexp, case_insensitive, format_type, json_output, truncate, details, external, show_all) -> None`: List deltas with optional filtering and status grouping.
56+
57+
By default, completed deltas are hidden. Use --all to show them.
5658

5759
The --filter flag does substring matching (case-insensitive).
5860
The --regexp flag filters on ID, name, and slug fields.
@@ -64,6 +66,8 @@ The --referenced-by/--not-referenced-by flags filter by reverse references.
6466
The --unaudited flag is sugar for --not-referenced-by audit -s completed.
6567

6668
Examples:
69+
list deltas # Shows active deltas (hides completed)
70+
list deltas --all # Shows all deltas
6771
list deltas -s draft,in-progress # Multi-value status filter
6872
list deltas --implements PROD-010.FR-004 # Reverse relationship query
6973
list deltas --spec PROD-010 # Deltas touching a spec
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
id: AUD-022
3+
slug: list_deltas_default_filtering
4+
name: Audit - list deltas default filtering
5+
created: "2026-03-22"
6+
updated: "2026-03-22"
7+
status: completed
8+
kind: audit
9+
delta: DE-123
10+
mode: conformance
11+
---
12+
13+
# AUD-022 – list deltas default filtering
14+
15+
## 1. Scope & Context
16+
17+
- **Delta**: DE-123
18+
- **Code Scope**: `supekku/cli/list.py`
19+
20+
## 2. Verification Evidence
21+
22+
```yaml supekku:verification.coverage@v1
23+
schema: supekku.verification.coverage
24+
version: 1
25+
subject: AUD-022
26+
entries:
27+
- artefact: VA-123-01
28+
kind: VA
29+
requirement: DE-123
30+
status: verified
31+
notes: |
32+
- `list deltas` hides completed deltas.
33+
- `list deltas --all` shows all deltas.
34+
- `list deltas -s completed` shows completed deltas.
35+
- `list deltas --unaudited` works correctly.
36+
```
37+
38+
## 3. Findings & Dispositions
39+
40+
| Finding | Outcome | Disposition |
41+
| ----------------- | -------------------------------------------------------------------- | ----------- |
42+
| Default filtering | `list deltas` now hides completed deltas by default, reducing noise. | aligned |
43+
| --all flag | `--all` flag correctly overrides default filtering. | aligned |
44+
| Existing filters | Status filters and `--unaudited` alias continue to work as expected. | aligned |
45+
46+
## 4. Reconciliation
47+
48+
- [x] CLI behavior updated and verified.
49+
- [x] No spec changes required (no technical spec specifically defines `list deltas` output filtering, but it aligns with general CLI consistency goals).
50+
51+
## 5. Closure Readiness
52+
53+
- [x] Every finding is `aligned`.
54+
- [x] Verification is complete.

.spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/DR-113.md

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -100,27 +100,27 @@ open_questions: []
100100

101101
### 4a. Deletions (orphaned scripts — zero non-test importers)
102102

103-
| Path | Lines | Notes |
104-
|------|-------|-------|
105-
| `scripts/list_specs.py` || argparse wrapper, superseded by `cli/list.py` |
106-
| `scripts/list_changes.py` || argparse wrapper, superseded by `cli/list.py` |
107-
| `scripts/list_deltas.py` || argparse wrapper, superseded by `cli/list.py` |
108-
| `scripts/change_registry.py` || argparse wrapper, superseded by CLI |
109-
| `scripts/create_delta.py` || argparse wrapper, superseded by `cli/create.py` |
110-
| `scripts/create_new_spec.py` || argparse wrapper, superseded by `cli/create.py` |
111-
| `scripts/create_revision.py` || argparse wrapper, superseded by `cli/create.py` |
112-
| `scripts/create_requirement.py` || argparse wrapper, superseded by `cli/create.py` |
113-
| `scripts/decision_registry.py` | 211 | 17 hollow `pass` bodies, fully orphaned |
114-
| `scripts/validate_workspace.py` || argparse wrapper, superseded by CLI |
115-
| `scripts/requirements.py` || argparse wrapper, superseded by CLI |
116-
| `scripts/validate_revision_blocks.py` || argparse wrapper over `lib/blocks/revision`, zero importers |
117-
| `scripts/migrate_stub_status.py` || one-time migration, stale |
118-
| `scripts/backlog/append.py` || orphaned |
119-
| `scripts/backlog/create_entry.py` || orphaned |
120-
| `scripts/backlog/__init__.py` || delete entire directory |
121-
| `scripts/cli/ast_doc_generator.py` || unreachable duplicate of `deterministic_ast_doc_generator.py` |
122-
| `scripts/lib/list_specs_test.py` || tests orphaned `list_specs.py` |
123-
| `scripts/lib/list_changes_test.py` || tests orphaned `list_changes.py` |
103+
| Path | Lines | Notes |
104+
| ------------------------------------- | ----- | ------------------------------------------------------------- |
105+
| `scripts/list_specs.py` | | argparse wrapper, superseded by `cli/list.py` |
106+
| `scripts/list_changes.py` | | argparse wrapper, superseded by `cli/list.py` |
107+
| `scripts/list_deltas.py` | | argparse wrapper, superseded by `cli/list.py` |
108+
| `scripts/change_registry.py` | | argparse wrapper, superseded by CLI |
109+
| `scripts/create_delta.py` | | argparse wrapper, superseded by `cli/create.py` |
110+
| `scripts/create_new_spec.py` | | argparse wrapper, superseded by `cli/create.py` |
111+
| `scripts/create_revision.py` | | argparse wrapper, superseded by `cli/create.py` |
112+
| `scripts/create_requirement.py` | | argparse wrapper, superseded by `cli/create.py` |
113+
| `scripts/decision_registry.py` | 211 | 17 hollow `pass` bodies, fully orphaned |
114+
| `scripts/validate_workspace.py` | | argparse wrapper, superseded by CLI |
115+
| `scripts/requirements.py` | | argparse wrapper, superseded by CLI |
116+
| `scripts/validate_revision_blocks.py` | | argparse wrapper over `lib/blocks/revision`, zero importers |
117+
| `scripts/migrate_stub_status.py` | | one-time migration, stale |
118+
| `scripts/backlog/append.py` | | orphaned |
119+
| `scripts/backlog/create_entry.py` | | orphaned |
120+
| `scripts/backlog/__init__.py` | | delete entire directory |
121+
| `scripts/cli/ast_doc_generator.py` | | unreachable duplicate of `deterministic_ast_doc_generator.py` |
122+
| `scripts/lib/list_specs_test.py` | | tests orphaned `list_specs.py` |
123+
| `scripts/lib/list_changes_test.py` | | tests orphaned `list_changes.py` |
124124

125125
### 4b. Relocation: `complete_delta.py``scripts/lib/changes/completion.py`
126126

@@ -147,12 +147,12 @@ open_questions: []
147147

148148
## 5. Verification Alignment
149149

150-
| Check | Method | Notes |
151-
|-------|--------|-------|
152-
| No broken imports | `just check` (test suite + lint) | full pass required |
153-
| No stale references | `grep -rn` for deleted module names | zero hits outside `.uv-cache` |
154-
| `registry_migration` gone | `grep -rn registry_migration` | zero hits in production/test code |
155-
| Zero behaviour change | existing test suite | no new tests needed; deleted tests covered deleted code |
150+
| Check | Method | Notes |
151+
| ------------------------- | ----------------------------------- | ------------------------------------------------------- |
152+
| No broken imports | `just check` (test suite + lint) | full pass required |
153+
| No stale references | `grep -rn` for deleted module names | zero hits outside `.uv-cache` |
154+
| `registry_migration` gone | `grep -rn registry_migration` | zero hits in production/test code |
155+
| Zero behaviour change | existing test suite | no new tests needed; deleted tests covered deleted code |
156156

157157
## 6. Design Decisions
158158

.spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/IP-113.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ entries:
6161

6262
## 4. Phase Overview
6363

64-
| Phase | Objective | Entrance Criteria | Exit Criteria | Phase Sheet |
65-
|-------|-----------|-------------------|---------------|-------------|
66-
| P01 — Purge & relocate | Delete orphaned scripts, relocate complete_delta, rename registry_migration, clean stale TODO | DR-113 accepted | `just check` passes, grep confirms no stale imports | `phases/phase-01.md` |
64+
| Phase | Objective | Entrance Criteria | Exit Criteria | Phase Sheet |
65+
| ---------------------- | --------------------------------------------------------------------------------------------- | ----------------- | --------------------------------------------------- | -------------------- |
66+
| P01 — Purge & relocate | Delete orphaned scripts, relocate complete_delta, rename registry_migration, clean stale TODO | DR-113 accepted | `just check` passes, grep confirms no stale imports | `phases/phase-01.md` |
6767

6868
Single phase — the work is mechanical and interdependencies are minimal.
6969

@@ -75,10 +75,10 @@ Single phase — the work is mechanical and interdependencies are minimal.
7575

7676
## 6. Risks & Mitigations
7777

78-
| Risk | Mitigation | Owner |
79-
|------|------------|-------|
80-
| Orphaned script invoked externally | Verified: pyproject.toml, Justfile, CI configs show no refs | — |
81-
| `complete_delta` relocation breaks CLI | Mechanical import update, existing test coverage | — |
78+
| Risk | Mitigation | Owner |
79+
| -------------------------------------- | ----------------------------------------------------------- | ----- |
80+
| Orphaned script invoked externally | Verified: pyproject.toml, Justfile, CI configs show no refs | — |
81+
| `complete_delta` relocation breaks CLI | Mechanical import update, existing test coverage | — |
8282

8383
## 7. Progress Tracking
8484

.spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/phases/phase-01.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -52,19 +52,19 @@ Delete 19 orphaned files (15 scripts + 2 tests + 1 duplicate doc generator + 1 s
5252

5353
## 7. Tasks & Progress
5454

55-
| Status | ID | Description | Parallel? | Notes |
56-
|--------|-----|-------------|-----------|-------|
57-
| [x] | 1.1 | Delete 15 orphaned scripts + backlog dir | [P] | 19 files removed |
58-
| [x] | 1.2 | Delete orphaned tests (`list_specs_test`, `list_changes_test`) | [P] | |
59-
| [x] | 1.3 | Delete `scripts/cli/ast_doc_generator.py` | [P] | |
60-
| [x] | 1.4 | Delete `migrate_stub_status.py` | [P] | |
61-
| [x] | 1.5 | Relocate `complete_delta` business logic to `completion.py` | | Hollow display fns deleted |
62-
| [x] | 1.6 | Update `cli/complete.py` import | | |
63-
| [x] | 1.7 | Move `complete_delta_test.py` to `lib/changes/` | | Patches updated |
64-
| [x] | 1.8 | Rename `registry_migration.py``registry_v2.py` | | |
65-
| [x] | 1.9 | Update 5 importers of `registry_migration` | | |
66-
| [x] | 1.10 | Clean stale TODO in `blocks/__init__.py` | [P] | |
67-
| [x] | 1.11 | Run tests + lint + grep verification | | See notes |
55+
| Status | ID | Description | Parallel? | Notes |
56+
| ------ | ---- | -------------------------------------------------------------- | --------- | -------------------------- |
57+
| [x] | 1.1 | Delete 15 orphaned scripts + backlog dir | [P] | 19 files removed |
58+
| [x] | 1.2 | Delete orphaned tests (`list_specs_test`, `list_changes_test`) | [P] | |
59+
| [x] | 1.3 | Delete `scripts/cli/ast_doc_generator.py` | [P] | |
60+
| [x] | 1.4 | Delete `migrate_stub_status.py` | [P] | |
61+
| [x] | 1.5 | Relocate `complete_delta` business logic to `completion.py` | | Hollow display fns deleted |
62+
| [x] | 1.6 | Update `cli/complete.py` import | | |
63+
| [x] | 1.7 | Move `complete_delta_test.py` to `lib/changes/` | | Patches updated |
64+
| [x] | 1.8 | Rename `registry_migration.py``registry_v2.py` | | |
65+
| [x] | 1.9 | Update 5 importers of `registry_migration` | | |
66+
| [x] | 1.10 | Clean stale TODO in `blocks/__init__.py` | [P] | |
67+
| [x] | 1.11 | Run tests + lint + grep verification | | See notes |
6868

6969
### Task Details
7070

@@ -92,10 +92,10 @@ Delete 19 orphaned files (15 scripts + 2 tests + 1 duplicate doc generator + 1 s
9292

9393
## 8. Risks & Mitigations
9494

95-
| Risk | Mitigation | Status |
96-
|------|------------|--------|
97-
| External caller of orphaned script | Verified pyproject.toml, Justfile, CI — none found | mitigated |
98-
| complete_delta relocation breaks CLI | Mechanical import update, test coverage | mitigated |
95+
| Risk | Mitigation | Status |
96+
| ------------------------------------ | -------------------------------------------------- | --------- |
97+
| External caller of orphaned script | Verified pyproject.toml, Justfile, CI — none found | mitigated |
98+
| complete_delta relocation breaks CLI | Mechanical import update, test coverage | mitigated |
9999

100100
## 9. Decisions & Outcomes
101101

.spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/workflow/handoff.current.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ phase:
1212
id: IP-113.PHASE-01
1313
status: complete
1414
required_reading:
15-
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/DE-113.md
16-
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/IP-113.md
17-
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/phases/phase-01.md
18-
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/notes.md
15+
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/DE-113.md
16+
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/IP-113.md
17+
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/phases/phase-01.md
18+
- .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/notes.md
1919
next_activity:
2020
kind: implementation
2121
timestamps:
22-
emitted_at: '2026-03-22T11:08:19+00:00'
22+
emitted_at: "2026-03-22T11:08:19+00:00"
2323
git:
2424
head: 9dd845f4
2525
branch: main

.spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/workflow/state.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ workflow:
1515
handoff_boundary: phase
1616
next_role: implementer
1717
timestamps:
18-
created: '2026-03-22T10:47:52+00:00'
19-
updated: '2026-03-22T11:08:19+00:00'
18+
created: "2026-03-22T10:47:52+00:00"
19+
updated: "2026-03-22T11:08:19+00:00"
2020
plan:
2121
id: IP-113
2222
path: .spec-driver/deltas/DE-113-dead_code_purge_orphaned_scripts_hollow_functions_stale_migrations/IP-113.md

0 commit comments

Comments
 (0)