Dev Tracking Data Compilersqlite

Saved queries

The six questions this database is built to answer. Each runs unchanged on SQLite and Postgres.

1. Acceptance criteria with no linked commits or no linked tests2. Commits not tied to any task3. Cycle time4. Requirements changed after the code for one of their criteria merged5. Review turnaround by reviewer6. Full trace for one requirement

6. Full trace for one requirement: requirement -> criteria -> tasks -> commits -> PRs -> reviews.

REQ-CLICK-01 REQ-CLICK-02 REQ-CLICK-03 REQ-HTTPX-01 REQ-HTTPX-02 REQ-HTTPX-03 REQ-REQ-01 REQ-REQ-02 REQ-REQ-03 SUB-CLI-01 SUB-HTTP-01 SYS-01
SQL
-- 6. Full trace for one requirement: requirement -> criteria -> tasks -> commits -> PRs -> reviews.
-- LEFT JOINs keep the gaps visible: a criterion with no task shows NULLs to the right.
SELECT r.key AS requirement,
       a.key AS criterion,
       a.text AS criterion_text,
       t.key AS task,
       t.status AS task_status,
       c.repo,
       c.sha,
       c.committed_at,
       pr.number AS pr_number,
       pr.title AS pr_title,
       pr.merged_at,
       rv.state AS review_state,
       rp.display_name AS reviewer,
       rv.submitted_at AS reviewed_at
FROM requirements r
JOIN requirement_criteria rc ON rc.requirement_id = r.id
JOIN acceptance_criteria a ON a.id = rc.criterion_id
LEFT JOIN task_criteria tc ON tc.criterion_id = a.id
LEFT JOIN tasks t ON t.id = tc.task_id
LEFT JOIN commit_tasks ct ON ct.task_id = t.id
LEFT JOIN commits c ON c.id = ct.commit_id
LEFT JOIN pull_request_commits prc ON prc.commit_id = c.id
LEFT JOIN pull_requests pr ON pr.id = prc.pull_request_id
LEFT JOIN reviews rv ON rv.pull_request_id = pr.id
LEFT JOIN people rp ON rp.id = rv.reviewer_id
WHERE r.key = ?
ORDER BY a.key, t.key, c.committed_at, rv.submitted_at;

10 rows

requirementcriterioncriterion_texttasktask_statusreposhacommitted_atpr_numberpr_titlemerged_atreview_statereviewerreviewed_at
REQ-CLICK-02AC-CLICK-102-1Help text wrapping measures line width in visible characters, so ANSI escape sequences don't count toward the width.TASK-CLICK-1021donepallets/clickd946074a8fd4bd743dcde12e08e1561f062a2a682026-05-12T15:50:52Z3420Make `TextWrapper` ANSI-aware2026-05-16T05:04:29ZCOMMENTEDNina Kowalski2026-05-14T06:24:50Z
REQ-CLICK-02AC-CLICK-102-1Help text wrapping measures line width in visible characters, so ANSI escape sequences don't count toward the width.TASK-CLICK-1021donepallets/clickd946074a8fd4bd743dcde12e08e1561f062a2a682026-05-12T15:50:52Z3420Make `TextWrapper` ANSI-aware2026-05-16T05:04:29ZAPPROVEDJamal Wright2026-05-15T20:28:05Z
REQ-CLICK-02AC-CLICK-102-2`confirm()` and `prompt()` remove colour codes from the prompt when the output stream doesn't support colour.TASK-CLICK-1022donepallets/click93ba0075f4881b858b61f89a753c7c10e330027e2026-07-01T05:18:55Z3653Strip ANSI from `confirm()` and `prompt()`2026-07-02T23:39:09ZCHANGES_REQUESTEDJamal Wright2026-06-30T22:48:18Z
REQ-CLICK-02AC-CLICK-102-2`confirm()` and `prompt()` remove colour codes from the prompt when the output stream doesn't support colour.TASK-CLICK-1022donepallets/click93ba0075f4881b858b61f89a753c7c10e330027e2026-07-01T05:18:55Z3653Strip ANSI from `confirm()` and `prompt()`2026-07-02T23:39:09ZCOMMENTEDNina Kowalski2026-07-01T23:15:12Z
REQ-CLICK-02AC-CLICK-102-2`confirm()` and `prompt()` remove colour codes from the prompt when the output stream doesn't support colour.TASK-CLICK-1022donepallets/click93ba0075f4881b858b61f89a753c7c10e330027e2026-07-01T05:18:55Z3653Strip ANSI from `confirm()` and `prompt()`2026-07-02T23:39:09ZAPPROVEDSofia Reyes2026-07-02T18:07:54Z
REQ-CLICK-02AC-CLICK-102-3`unstyle()` removes colon-delimited true-colour sequences such as `\x1b[38:2:255:0:0m`.TASK-CLICK-1023donepallets/click71f2bafa541e7f798834e74076786ff4281ac83e2026-07-09T14:00:50Z3681Strip all ANSI sequences2026-07-10T03:14:25ZAPPROVEDSofia Reyes2026-07-09T05:41:38Z
REQ-CLICK-02AC-CLICK-102-4`style()` raises an error for an invalid colour name, and the error message lists the valid colour names.TASK-CLICK-1024donepallets/click07c909f23f0f83b5ca137c167b9a134d66201f672026-07-08T14:46:39Z3677Validate `style()` color arguments2026-07-08T16:05:23ZCOMMENTEDJamal Wright2026-07-08T13:58:16Z
REQ-CLICK-02AC-CLICK-102-4`style()` raises an error for an invalid colour name, and the error message lists the valid colour names.TASK-CLICK-1024donepallets/click07c909f23f0f83b5ca137c167b9a134d66201f672026-07-08T14:46:39Z3677Validate `style()` color arguments2026-07-08T16:05:23ZAPPROVEDSofia Reyes2026-07-08T15:36:54Z
REQ-CLICK-02AC-CLICK-102-5Passing `fg=0` to `style()` produces the 256-colour code for black instead of being silently ignored.TASK-CLICK-1024donepallets/click07c909f23f0f83b5ca137c167b9a134d66201f672026-07-08T14:46:39Z3677Validate `style()` color arguments2026-07-08T16:05:23ZCOMMENTEDJamal Wright2026-07-08T13:58:16Z
REQ-CLICK-02AC-CLICK-102-5Passing `fg=0` to `style()` produces the 256-colour code for black instead of being silently ignored.TASK-CLICK-1024donepallets/click07c909f23f0f83b5ca137c167b9a134d66201f672026-07-08T14:46:39Z3677Validate `style()` color arguments2026-07-08T16:05:23ZAPPROVEDSofia Reyes2026-07-08T15:36:54Z