blitz-cli 0.17.0__tar.gz → 0.17.1__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 (182) hide show
  1. blitz_cli-0.17.1/.github/workflows/secret-scan.yml +72 -0
  2. blitz_cli-0.17.1/.github/workflows/tests.yml +41 -0
  3. blitz_cli-0.17.1/.github/workflows/vuln-scan.yml +141 -0
  4. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/PKG-INFO +50 -9
  5. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/README.md +48 -7
  6. blitz_cli-0.17.1/blitz.toml +13 -0
  7. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_collect.py +218 -143
  8. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_collect_http.py +51 -0
  9. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_collect_server.py +46 -2
  10. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_execute.py +121 -7
  11. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_ontology.py +28 -1
  12. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_secretscan.py +90 -8
  13. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/cli.py +220 -86
  14. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/implement.md +13 -8
  15. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/workspace/huddle.md +6 -0
  16. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/templates/locker_room_compose.yml.tmpl +2 -2
  17. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/pyproject.toml +6 -2
  18. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/checklists/requirements.md +35 -0
  19. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/contracts/secret-scan-workflow.md +62 -0
  20. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/data-model.md +61 -0
  21. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/plan.md +114 -0
  22. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/quickstart.md +79 -0
  23. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/research.md +87 -0
  24. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/spec.md +122 -0
  25. blitz_cli-0.17.1/specs/009-ci-secret-scan-workflow/tasks.md +201 -0
  26. blitz_cli-0.17.1/specs/010-collect-by-default/checklists/requirements.md +37 -0
  27. blitz_cli-0.17.1/specs/010-collect-by-default/contracts/cli-execute.md +75 -0
  28. blitz_cli-0.17.1/specs/010-collect-by-default/data-model.md +54 -0
  29. blitz_cli-0.17.1/specs/010-collect-by-default/plan.md +120 -0
  30. blitz_cli-0.17.1/specs/010-collect-by-default/quickstart.md +99 -0
  31. blitz_cli-0.17.1/specs/010-collect-by-default/research.md +119 -0
  32. blitz_cli-0.17.1/specs/010-collect-by-default/spec.md +142 -0
  33. blitz_cli-0.17.1/specs/010-collect-by-default/tasks.md +268 -0
  34. blitz_cli-0.17.1/specs/011-huddle-status-normalization/checklists/requirements.md +35 -0
  35. blitz_cli-0.17.1/specs/011-huddle-status-normalization/contracts/normalize_status.md +40 -0
  36. blitz_cli-0.17.1/specs/011-huddle-status-normalization/data-model.md +60 -0
  37. blitz_cli-0.17.1/specs/011-huddle-status-normalization/plan.md +78 -0
  38. blitz_cli-0.17.1/specs/011-huddle-status-normalization/quickstart.md +72 -0
  39. blitz_cli-0.17.1/specs/011-huddle-status-normalization/research.md +39 -0
  40. blitz_cli-0.17.1/specs/011-huddle-status-normalization/spec.md +95 -0
  41. blitz_cli-0.17.1/specs/011-huddle-status-normalization/tasks.md +127 -0
  42. blitz_cli-0.17.1/specs/011-sft-solution-loop/checklists/requirements.md +37 -0
  43. blitz_cli-0.17.1/specs/011-sft-solution-loop/contracts/cli-sft.md +138 -0
  44. blitz_cli-0.17.1/specs/011-sft-solution-loop/contracts/ingest-attempt.md +72 -0
  45. blitz_cli-0.17.1/specs/011-sft-solution-loop/data-model.md +110 -0
  46. blitz_cli-0.17.1/specs/011-sft-solution-loop/plan.md +123 -0
  47. blitz_cli-0.17.1/specs/011-sft-solution-loop/quickstart.md +146 -0
  48. blitz_cli-0.17.1/specs/011-sft-solution-loop/research.md +175 -0
  49. blitz_cli-0.17.1/specs/011-sft-solution-loop/spec.md +233 -0
  50. blitz_cli-0.17.1/specs/011-sft-solution-loop/tasks.md +314 -0
  51. blitz_cli-0.17.1/tests/conftest.py +42 -0
  52. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_cli.py +147 -35
  53. blitz_cli-0.17.1/tests/test_collect.py +201 -0
  54. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_collect_http.py +46 -2
  55. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_collect_server.py +49 -0
  56. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_execute.py +173 -0
  57. blitz_cli-0.17.1/tests/test_execute_collect_default.py +288 -0
  58. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_ontology.py +69 -0
  59. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_secretscan.py +36 -0
  60. blitz_cli-0.17.1/tests/test_sft_endpoint.py +140 -0
  61. blitz_cli-0.17.1/tests/test_sft_queue.py +404 -0
  62. blitz_cli-0.17.0/tests/test_collect.py +0 -358
  63. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.blitz/memory/playbook.md +0 -0
  64. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.claude/settings.json +0 -0
  65. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.github/workflows/homebrew.yml +0 -0
  66. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.github/workflows/publish.yml +0 -0
  67. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.gitignore +0 -0
  68. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/.mcp.json +0 -0
  69. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/LICENSE +0 -0
  70. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/__init__.py +0 -0
  71. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_activity.py +0 -0
  72. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_code_graph.py +0 -0
  73. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_corpus.py +0 -0
  74. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_dataset.py +0 -0
  75. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_git.py +0 -0
  76. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_gitignore.py +0 -0
  77. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_make.py +0 -0
  78. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_playbooks.py +0 -0
  79. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_redact.py +0 -0
  80. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_scaffold.py +0 -0
  81. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_secrets.py +0 -0
  82. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_tool_schemas.py +0 -0
  83. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/_train.py +0 -0
  84. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/__init__.py +0 -0
  85. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/__init__.py +0 -0
  86. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/analyze.md +0 -0
  87. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/clarify.md +0 -0
  88. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/plan.md +0 -0
  89. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/playbook.md +0 -0
  90. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/specify.md +0 -0
  91. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/commands/tasks.md +0 -0
  92. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/memory/playbook.md +0 -0
  93. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/scripts/bash/check-prerequisites.sh +0 -0
  94. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/scripts/bash/common.sh +0 -0
  95. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/scripts/bash/create-new-feature.sh +0 -0
  96. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/scripts/bash/setup-plan.sh +0 -0
  97. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/scripts/bash/setup-tasks.sh +0 -0
  98. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/templates/plan-template.md +0 -0
  99. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/templates/spec-template.md +0 -0
  100. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/scaffold/.blitz/templates/tasks-template.md +0 -0
  101. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/playbooks/workspace/__init__.py +0 -0
  102. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/templates/__init__.py +0 -0
  103. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/templates/locker_room_Makefile.tmpl +0 -0
  104. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/templates/locker_room_README.md.tmpl +0 -0
  105. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/blitz_cli/templates/workspace_playbook.md.tmpl +0 -0
  106. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/checklists/requirements.md +0 -0
  107. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/contracts/cli-commands.md +0 -0
  108. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/plan.md +0 -0
  109. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/quickstart.md +0 -0
  110. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/research.md +0 -0
  111. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/spec.md +0 -0
  112. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/001-cli-model-namespace/tasks.md +0 -0
  113. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/checklists/requirements.md +0 -0
  114. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/contracts/experimental-labels.md +0 -0
  115. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/data-model.md +0 -0
  116. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/plan.md +0 -0
  117. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/quickstart.md +0 -0
  118. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/research.md +0 -0
  119. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/spec.md +0 -0
  120. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/002-label-experimental-surfaces/tasks.md +0 -0
  121. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/checklists/requirements.md +0 -0
  122. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/contracts/cli-output.md +0 -0
  123. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/contracts/ensure-rules.md +0 -0
  124. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/contracts/gitignore-block.md +0 -0
  125. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/data-model.md +0 -0
  126. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/plan.md +0 -0
  127. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/quickstart.md +0 -0
  128. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/research.md +0 -0
  129. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/spec.md +0 -0
  130. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/003-init-gitignore-rules/tasks.md +0 -0
  131. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/checklists/requirements.md +0 -0
  132. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/contracts/cli.md +0 -0
  133. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/contracts/export-format.md +0 -0
  134. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/data-model.md +0 -0
  135. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/plan.md +0 -0
  136. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/quickstart.md +0 -0
  137. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/research.md +0 -0
  138. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/spec.md +0 -0
  139. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/004-dpo-collect-pairs/tasks.md +0 -0
  140. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/checklists/requirements.md +0 -0
  141. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/contracts/client-sink.md +0 -0
  142. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/contracts/ingest-api.md +0 -0
  143. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/data-model.md +0 -0
  144. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/plan.md +0 -0
  145. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/quickstart.md +0 -0
  146. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/research.md +0 -0
  147. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/spec.md +0 -0
  148. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/005-collect-ingest-endpoint/tasks.md +0 -0
  149. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/checklists/requirements.md +0 -0
  150. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/contracts/gitignore-block.md +0 -0
  151. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/data-model.md +0 -0
  152. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/plan.md +0 -0
  153. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/quickstart.md +0 -0
  154. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/research.md +0 -0
  155. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/spec.md +0 -0
  156. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/006-init-ignore-generated/tasks.md +0 -0
  157. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/checklists/requirements.md +0 -0
  158. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/contracts/activity-db-v2.md +0 -0
  159. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/data-model.md +0 -0
  160. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/plan.md +0 -0
  161. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/quickstart.md +0 -0
  162. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/research.md +0 -0
  163. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/spec.md +0 -0
  164. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/007-usage-data-layer/tasks.md +0 -0
  165. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/checklists/requirements.md +0 -0
  166. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/contracts/cli-secrets-install-hook.md +0 -0
  167. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/contracts/cli-secrets-scan.md +0 -0
  168. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/data-model.md +0 -0
  169. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/plan.md +0 -0
  170. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/quickstart.md +0 -0
  171. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/research.md +0 -0
  172. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/spec.md +0 -0
  173. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/specs/008-secrets-scan/tasks.md +0 -0
  174. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_activity.py +0 -0
  175. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_corpus.py +0 -0
  176. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_gitignore.py +0 -0
  177. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_make.py +0 -0
  178. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_playbooks.py +0 -0
  179. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_redact.py +0 -0
  180. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_scaffold.py +0 -0
  181. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_secrets.py +0 -0
  182. {blitz_cli-0.17.0 → blitz_cli-0.17.1}/tests/test_tool_schemas.py +0 -0
@@ -0,0 +1,72 @@
1
+ name: Secret scan
2
+
3
+ on:
4
+ workflow_call:
5
+ inputs:
6
+ blitz-version:
7
+ description: "Pinned blitz-cli version to install. Empty installs the latest release."
8
+ type: string
9
+ required: false
10
+ default: ""
11
+ python-version:
12
+ description: "Python runtime version for the scanner."
13
+ type: string
14
+ required: false
15
+ default: "3.12"
16
+ pull_request:
17
+ push:
18
+ branches: [main]
19
+
20
+ jobs:
21
+ secrets:
22
+ runs-on: ubuntu-latest
23
+ permissions:
24
+ contents: read
25
+ steps:
26
+ - name: Check out full history
27
+ uses: actions/checkout@v4
28
+ with:
29
+ fetch-depth: 0
30
+
31
+ - name: Set up Python
32
+ uses: actions/setup-python@v5
33
+ with:
34
+ python-version: ${{ inputs.python-version || '3.12' }}
35
+
36
+ - name: Install blitz-cli
37
+ env:
38
+ BLITZ_VERSION: ${{ inputs.blitz-version }}
39
+ run: |
40
+ # Dogfood: when the checked-out repo IS blitz-cli, scan with its own
41
+ # current source rather than the published release, so a PR that
42
+ # changes the scanner is checked by the code it ships.
43
+ if grep -q '^name = "blitz-cli"' pyproject.toml 2>/dev/null; then
44
+ pip install -e .
45
+ elif [ -n "$BLITZ_VERSION" ]; then
46
+ pip install "blitz-cli==$BLITZ_VERSION"
47
+ else
48
+ pip install blitz-cli
49
+ fi
50
+
51
+ - name: Resolve commit range
52
+ id: range
53
+ env:
54
+ EVENT_NAME: ${{ github.event_name }}
55
+ PR_BASE: ${{ github.event.pull_request.base.sha }}
56
+ PR_HEAD: ${{ github.event.pull_request.head.sha }}
57
+ PUSH_BEFORE: ${{ github.event.before }}
58
+ PUSH_AFTER: ${{ github.event.after }}
59
+ run: |
60
+ if [ "$EVENT_NAME" = "pull_request" ]; then
61
+ echo "range=${PR_BASE}..${PR_HEAD}" >> "$GITHUB_OUTPUT"
62
+ elif [ "$PUSH_BEFORE" = "0000000000000000000000000000000000000000" ]; then
63
+ echo "range=${PUSH_AFTER}" >> "$GITHUB_OUTPUT"
64
+ else
65
+ echo "range=${PUSH_BEFORE}..${PUSH_AFTER}" >> "$GITHUB_OUTPUT"
66
+ fi
67
+
68
+ - name: Scan range for secrets
69
+ env:
70
+ RANGE: ${{ steps.range.outputs.range }}
71
+ run: |
72
+ blitz secrets scan --range "$RANGE"
@@ -0,0 +1,41 @@
1
+ name: Tests
2
+
3
+ # Run the unit suite on every pull request and on main.
4
+ on:
5
+ pull_request:
6
+ push:
7
+ branches: [main]
8
+
9
+ # A newer push to the same branch makes an in-flight run redundant.
10
+ concurrency:
11
+ group: tests-${{ github.workflow }}-${{ github.ref }}
12
+ cancel-in-progress: true
13
+
14
+ jobs:
15
+ pytest:
16
+ runs-on: ubuntu-latest
17
+ strategy:
18
+ # Report every version's result; one failure should not mask the others.
19
+ fail-fast: false
20
+ matrix:
21
+ # 3.11 is the floor declared by requires-python and the runtime the
22
+ # locker-room core image ships, so it is the version a change has to
23
+ # keep working. Add versions here to widen coverage.
24
+ python-version: ["3.11"]
25
+ steps:
26
+ - name: Check out
27
+ uses: actions/checkout@v4
28
+
29
+ - name: Set up Python ${{ matrix.python-version }}
30
+ uses: actions/setup-python@v5
31
+ with:
32
+ python-version: ${{ matrix.python-version }}
33
+
34
+ - name: Install
35
+ # pytest is not a package dependency, so it is installed explicitly.
36
+ run: |
37
+ python -m pip install --upgrade pip
38
+ pip install -e . pytest
39
+
40
+ - name: Run tests
41
+ run: pytest -q
@@ -0,0 +1,141 @@
1
+ name: Vulnerability scan
2
+
3
+ on:
4
+ workflow_call:
5
+ inputs:
6
+ python-extras:
7
+ description: "Extras to install for the blocking scan, e.g. \"secrets\". Empty installs the base dependencies only."
8
+ type: string
9
+ required: false
10
+ default: ""
11
+ python-extras-advisory:
12
+ description: "Extras scanned for visibility only -- findings are reported but never fail the build."
13
+ type: string
14
+ required: false
15
+ default: ""
16
+ python-version:
17
+ description: "Python runtime used to resolve the dependency tree."
18
+ type: string
19
+ required: false
20
+ default: "3.12"
21
+ severity:
22
+ description: "Comma-separated severities that fail the build."
23
+ type: string
24
+ required: false
25
+ default: "HIGH,CRITICAL"
26
+ pull_request:
27
+ push:
28
+ branches: [main]
29
+
30
+ permissions:
31
+ contents: read
32
+
33
+ jobs:
34
+ scan:
35
+ runs-on: ubuntu-latest
36
+ steps:
37
+ - uses: actions/checkout@v4
38
+
39
+ - uses: actions/setup-python@v5
40
+ with:
41
+ python-version: ${{ inputs.python-version || '3.12' }}
42
+
43
+ # A PEP 621 project with no lockfile has no dependency tree Trivy can read:
44
+ # it does not parse pyproject.toml, and its installed-package analyzer runs
45
+ # only on image/rootfs targets, never on a filesystem scan. So resolve the
46
+ # deps into a venv and freeze them to a pinned requirements.txt, which the
47
+ # filesystem scan does parse. This also gets the transitive deps scanned,
48
+ # which is where most advisories actually land. Repos with no pyproject (the
49
+ # locker-room node pip-installs inside its Dockerfile) skip this and are
50
+ # covered by their own image scan.
51
+ - name: Resolve Python dependencies
52
+ env:
53
+ EXTRAS: ${{ inputs.python-extras }}
54
+ run: |
55
+ if [ ! -f pyproject.toml ]; then
56
+ echo "No pyproject.toml -- nothing to resolve; lockfile scanning still applies."
57
+ exit 0
58
+ fi
59
+ # Dogfood: when the checked-out repo IS blitz-cli, `secrets` is the only
60
+ # extra that belongs in the blocking set. `train` is handled below.
61
+ if [ -z "$EXTRAS" ] && grep -q '^name = "blitz-cli"' pyproject.toml; then
62
+ EXTRAS="secrets"
63
+ fi
64
+ python -m venv /tmp/vulnscan-venv
65
+ if [ -n "$EXTRAS" ]; then
66
+ echo "Installing .[$EXTRAS]"
67
+ /tmp/vulnscan-venv/bin/pip install -q ".[$EXTRAS]"
68
+ else
69
+ /tmp/vulnscan-venv/bin/pip install -q .
70
+ fi
71
+ # Written into the workspace so the single fs scan below picks it up
72
+ # alongside any committed lockfiles. CI-only; never committed.
73
+ mkdir -p .vulnscan
74
+ /tmp/vulnscan-venv/bin/pip freeze --exclude-editable > .vulnscan/requirements.txt
75
+ echo "Resolved $(wc -l < .vulnscan/requirements.txt) packages for scanning."
76
+
77
+ # One filesystem scan covers the resolved requirements above and any
78
+ # committed lockfiles (package-lock.json in the locker-room UI).
79
+ # --ignore-unfixed keeps the gate actionable: an advisory with no released
80
+ # fix is not something a PR author can resolve, so it stays out of the way.
81
+ - name: Scan dependencies
82
+ uses: aquasecurity/trivy-action@v0.36.0
83
+ with:
84
+ scan-type: fs
85
+ scan-ref: .
86
+ scanners: vuln
87
+ severity: ${{ inputs.severity || 'HIGH,CRITICAL' }}
88
+ ignore-unfixed: true
89
+ exit-code: "1"
90
+ format: table
91
+
92
+ # The heavy ML extras get their own check so their findings are visible at a
93
+ # glance in the PR rather than buried in another job's log. It reports but never
94
+ # blocks: the current pins carry known HIGH/CRITICAL advisories (mostly mlflow
95
+ # tracking-server RCE/traversal issues) whose fixes are major breaking upgrades
96
+ # -- mlflow 2.x->3.x and transformers 4.x->5.x -- so gating on them would mean a
97
+ # permanently red CI that no individual PR can turn green.
98
+ advisory:
99
+ runs-on: ubuntu-latest
100
+ continue-on-error: true
101
+ steps:
102
+ - uses: actions/checkout@v4
103
+
104
+ - uses: actions/setup-python@v5
105
+ with:
106
+ python-version: ${{ inputs.python-version || '3.12' }}
107
+
108
+ - name: Resolve advisory extras
109
+ id: advisory
110
+ env:
111
+ EXTRAS: ${{ inputs.python-extras-advisory }}
112
+ run: |
113
+ if [ ! -f pyproject.toml ]; then exit 0; fi
114
+ if [ -z "$EXTRAS" ] && grep -q '^name = "blitz-cli"' pyproject.toml; then
115
+ EXTRAS="train"
116
+ fi
117
+ if [ -z "$EXTRAS" ]; then
118
+ echo "No advisory extras configured."
119
+ exit 0
120
+ fi
121
+ python -m venv /tmp/vulnscan-advisory-venv
122
+ echo "Installing .[$EXTRAS]"
123
+ /tmp/vulnscan-advisory-venv/bin/pip install -q ".[$EXTRAS]"
124
+ # Scanned from its own directory so this job shares no state with the
125
+ # blocking scan and cannot affect its result.
126
+ mkdir -p .vulnscan-advisory
127
+ /tmp/vulnscan-advisory-venv/bin/pip freeze --exclude-editable \
128
+ > .vulnscan-advisory/requirements.txt
129
+ echo "present=true" >> "$GITHUB_OUTPUT"
130
+
131
+ - name: Scan advisory extras
132
+ if: steps.advisory.outputs.present == 'true'
133
+ uses: aquasecurity/trivy-action@v0.36.0
134
+ with:
135
+ scan-type: fs
136
+ scan-ref: .vulnscan-advisory
137
+ scanners: vuln
138
+ severity: ${{ inputs.severity || 'HIGH,CRITICAL' }}
139
+ ignore-unfixed: true
140
+ exit-code: "1"
141
+ format: table
@@ -1,10 +1,10 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: blitz-cli
3
- Version: 0.17.0
3
+ Version: 0.17.1
4
4
  Summary: Developer CLI for Blitz locker-room: spec-driven playbooks, a codebase/huddle ontology graph with an MCP tool, and the composable watcher/trainer/graph containers.
5
5
  License: MIT
6
6
  License-File: LICENSE
7
- Requires-Python: >=3.9
7
+ Requires-Python: >=3.11
8
8
  Requires-Dist: rich>=13
9
9
  Provides-Extra: secrets
10
10
  Requires-Dist: boto3>=1.34; extra == 'secrets'
@@ -81,8 +81,10 @@ Ollama endpoint comes from `--ollama-url` or `OLLAMA_HOST`; the model from
81
81
 
82
82
  ### Collection over the ingest endpoint
83
83
 
84
- `blitz model execute --collect` records every generation attempt as DPO
85
- training data. By default it writes straight to the activity SQLite database
84
+ `blitz model execute` records every generation attempt as SFT training data.
85
+ Collection is on by default; pass `--no-collect` to turn it off, in which case
86
+ no database is opened at all. By default it writes straight to the activity
87
+ SQLite database
86
88
  (`BLITZ_ACTIVITY_DB_PATH`, else `data/activity.db`). With `BLITZ_COLLECT_ENDPOINT` set,
87
89
  the same writes go over HTTP JSON to a collect ingest server instead, so the
88
90
  collector needs no filesystem access to the database:
@@ -92,12 +94,13 @@ collector needs no filesystem access to the database:
92
94
  BLITZ_ACTIVITY_DB_PATH=data/activity.db blitz locker-room collect-serve
93
95
 
94
96
  # on the collecting machine:
95
- BLITZ_COLLECT_ENDPOINT=http://locker-room-host:1739 blitz model execute --collect
97
+ BLITZ_COLLECT_ENDPOINT=http://locker-room-host:1739 blitz model execute
96
98
  ```
97
99
 
98
100
  Each attempt is acknowledged by the endpoint before the next model call
99
- starts. If the endpoint is unreachable when the run starts, the run fails
100
- fast, same as an unwritable database. If it fails mid-run, the run keeps
101
+ starts. If the endpoint is unreachable when the run starts, the run warns on
102
+ stderr and continues without collection, same as an unwritable database. If it
103
+ fails mid-run, the run keeps
101
104
  going: undelivered payloads are buffered to `collect-buffer.jsonl` in the run
102
105
  directory and the final output names the file. Deliver them later with
103
106
 
@@ -107,8 +110,46 @@ blitz model collect flush .blitz/execute/runs/<stamp>/collect-buffer.jsonl
107
110
 
108
111
  Flushing is idempotent (the server deduplicates attempts on their
109
112
  run/task/sample/attempt identity), so re-running a flush, or flushing rows the
110
- server already received, never duplicates data. `pairs extract/export/stats`
111
- read the database directly, unaffected by the endpoint.
113
+ server already received, never duplicates data. `blitz model sft` reads the
114
+ database directly, unaffected by the endpoint.
115
+
116
+ `blitz model execute` exits 0 when the run completes, 1 when it completes with
117
+ unsolved tasks, and 2 when it aborts on an environment failure: the model
118
+ endpoint became unreachable, everything collected before the failure was saved,
119
+ and the remaining tasks were not attempted. An outage is recorded as an
120
+ environment failure on the attempt and never queues a task for repair.
121
+
122
+ ### The repair queue: `blitz model sft`
123
+
124
+ A task the local model does not solve leaves a placeholder in the repair queue,
125
+ awaiting a reference solution. Attaching the frontier's repair to that
126
+ placeholder is what turns a failed run into supervised training data.
127
+
128
+ ```bash
129
+ blitz model sft stats [--run RUN_ID] # attempt counts, pass rates, queue depth
130
+ blitz model sft solve --run RUN_ID --task T014 --solution-file repair.patch
131
+ blitz model sft queue --run RUN_ID --task T009
132
+ ```
133
+
134
+ `sft stats` reports, per run, the attempt count, per-task pass rates with the
135
+ 20 to 80 percent band marked, and the repair-queue depth.
136
+
137
+ `sft solve` attaches a reference solution to a queued task, setting it to
138
+ `has_solution` and attributing it to `frontier`. Give the solution with
139
+ `--solution TEXT`, `--solution-file PATH`, or `--solution-stdin`. A task that
140
+ already has a solution is left alone unless you pass `--force`. The solution
141
+ lands on the queue row only: the collected attempt record holds local-model
142
+ output and never receives frontier text.
143
+
144
+ `sft queue` queues a task after the fact, for the case where the local model
145
+ reported a task complete and the work was not done. The default reason is
146
+ `false_success`, which keeps it distinguishable from a task that honestly
147
+ exhausted its retries. The prompt is reused from the run's earliest recorded
148
+ attempt for that task; pass `--prompt-file PATH` when the run recorded none. A
149
+ row that already carries a solution is left unchanged.
150
+
151
+ Every subcommand takes `--db PATH` (default: `BLITZ_ACTIVITY_DB_PATH`, else
152
+ `data/activity.db`).
112
153
 
113
154
  ## Locker-room: ontology graph, watcher, trainer, MCP
114
155
 
@@ -58,8 +58,10 @@ Ollama endpoint comes from `--ollama-url` or `OLLAMA_HOST`; the model from
58
58
 
59
59
  ### Collection over the ingest endpoint
60
60
 
61
- `blitz model execute --collect` records every generation attempt as DPO
62
- training data. By default it writes straight to the activity SQLite database
61
+ `blitz model execute` records every generation attempt as SFT training data.
62
+ Collection is on by default; pass `--no-collect` to turn it off, in which case
63
+ no database is opened at all. By default it writes straight to the activity
64
+ SQLite database
63
65
  (`BLITZ_ACTIVITY_DB_PATH`, else `data/activity.db`). With `BLITZ_COLLECT_ENDPOINT` set,
64
66
  the same writes go over HTTP JSON to a collect ingest server instead, so the
65
67
  collector needs no filesystem access to the database:
@@ -69,12 +71,13 @@ collector needs no filesystem access to the database:
69
71
  BLITZ_ACTIVITY_DB_PATH=data/activity.db blitz locker-room collect-serve
70
72
 
71
73
  # on the collecting machine:
72
- BLITZ_COLLECT_ENDPOINT=http://locker-room-host:1739 blitz model execute --collect
74
+ BLITZ_COLLECT_ENDPOINT=http://locker-room-host:1739 blitz model execute
73
75
  ```
74
76
 
75
77
  Each attempt is acknowledged by the endpoint before the next model call
76
- starts. If the endpoint is unreachable when the run starts, the run fails
77
- fast, same as an unwritable database. If it fails mid-run, the run keeps
78
+ starts. If the endpoint is unreachable when the run starts, the run warns on
79
+ stderr and continues without collection, same as an unwritable database. If it
80
+ fails mid-run, the run keeps
78
81
  going: undelivered payloads are buffered to `collect-buffer.jsonl` in the run
79
82
  directory and the final output names the file. Deliver them later with
80
83
 
@@ -84,8 +87,46 @@ blitz model collect flush .blitz/execute/runs/<stamp>/collect-buffer.jsonl
84
87
 
85
88
  Flushing is idempotent (the server deduplicates attempts on their
86
89
  run/task/sample/attempt identity), so re-running a flush, or flushing rows the
87
- server already received, never duplicates data. `pairs extract/export/stats`
88
- read the database directly, unaffected by the endpoint.
90
+ server already received, never duplicates data. `blitz model sft` reads the
91
+ database directly, unaffected by the endpoint.
92
+
93
+ `blitz model execute` exits 0 when the run completes, 1 when it completes with
94
+ unsolved tasks, and 2 when it aborts on an environment failure: the model
95
+ endpoint became unreachable, everything collected before the failure was saved,
96
+ and the remaining tasks were not attempted. An outage is recorded as an
97
+ environment failure on the attempt and never queues a task for repair.
98
+
99
+ ### The repair queue: `blitz model sft`
100
+
101
+ A task the local model does not solve leaves a placeholder in the repair queue,
102
+ awaiting a reference solution. Attaching the frontier's repair to that
103
+ placeholder is what turns a failed run into supervised training data.
104
+
105
+ ```bash
106
+ blitz model sft stats [--run RUN_ID] # attempt counts, pass rates, queue depth
107
+ blitz model sft solve --run RUN_ID --task T014 --solution-file repair.patch
108
+ blitz model sft queue --run RUN_ID --task T009
109
+ ```
110
+
111
+ `sft stats` reports, per run, the attempt count, per-task pass rates with the
112
+ 20 to 80 percent band marked, and the repair-queue depth.
113
+
114
+ `sft solve` attaches a reference solution to a queued task, setting it to
115
+ `has_solution` and attributing it to `frontier`. Give the solution with
116
+ `--solution TEXT`, `--solution-file PATH`, or `--solution-stdin`. A task that
117
+ already has a solution is left alone unless you pass `--force`. The solution
118
+ lands on the queue row only: the collected attempt record holds local-model
119
+ output and never receives frontier text.
120
+
121
+ `sft queue` queues a task after the fact, for the case where the local model
122
+ reported a task complete and the work was not done. The default reason is
123
+ `false_success`, which keeps it distinguishable from a task that honestly
124
+ exhausted its retries. The prompt is reused from the run's earliest recorded
125
+ attempt for that task; pass `--prompt-file PATH` when the run recorded none. A
126
+ row that already carries a solution is left unchanged.
127
+
128
+ Every subcommand takes `--db PATH` (default: `BLITZ_ACTIVITY_DB_PATH`, else
129
+ `data/activity.db`).
89
130
 
90
131
  ## Locker-room: ontology graph, watcher, trainer, MCP
91
132
 
@@ -0,0 +1,13 @@
1
+ # blitz secret-scan allowlist for this repo (the scanner's own source).
2
+ # Entries match a repo-relative `path` exactly or a glob `pattern`.
3
+ [secrets]
4
+ allowlist = [
5
+ # The scanner's test suite deliberately contains secret-shaped fixtures
6
+ # (fake API keys, `SECRET_KEY = "..."`, etc.) to exercise the detectors.
7
+ # They are not real credentials.
8
+ { path = "tests/test_secretscan.py" },
9
+ # Spec quickstart guides are example env-var assignments and path tokens
10
+ # (BLITZ_ACTIVITY_DB_PATH=/tmp/..., etc.) that the high-entropy detector
11
+ # mistakes for base64 credentials.
12
+ { pattern = "*quickstart.md" },
13
+ ]