Using also_delete_snapshots parameter
What changed, and why it matters
This commit only changes a GitHub Actions CI workflow file. It adds a new optional checkbox that lets maintainers choose to delete outdated test snapshot files when automatically regenerating snapshots during a manual test run. There is no change to the Bitcoin app code, device firmware, cryptography, or anything users install.
No security action needed. Treat as routine CI maintenance.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The diff adds a workflow_dispatch input named delete_obsolete_snapshots and passes it as also_delete_snapshots to a reusable Ledger workflow (likely ledger-app-workflows). This controls whether obsolete golden/snapshot files are removed when a PR is opened to regenerate test snapshots. It is purely a CI maintenance convenience flag.
Changed components
.github/workflows/build_and_functional_tests.ymlInspect captured patch +6 / −0
diff --git a/.github/workflows/build_and_functional_tests.yml b/.github/workflows/build_and_functional_tests.yml
index 51b11ab..bf218dd 100644
--- a/.github/workflows/build_and_functional_tests.yml
+++ b/.github/workflows/build_and_functional_tests.yml
@@ -20,6 +20,11 @@ on:
options:
- 'Raise an error (default)'
- 'Open a PR'
+ delete_obsolete_snapshots:
+ type: boolean
+ required: false
+ default: false
+ description: When opening a PR, also delete snapshots that are no longer generated (e.g. for removed/renamed tests). Only safe for a full-suite regeneration.
push:
branches:
- master
@@ -47,6 +52,7 @@ jobs:
# when merging a PR, we run the tests with the --enable_slow_tests parameter
test_options: ${{ github.event_name == 'push' && '--enable_slow_tests' || '' }}
regenerate_snapshots: ${{ github.event_name == 'workflow_dispatch' && inputs.golden_run == 'Open a PR' }}
+ also_delete_snapshots: ${{ github.event_name == 'workflow_dispatch' && inputs.golden_run == 'Open a PR' && inputs.delete_obsolete_snapshots }}
post_stack_consumption: true
ragger_coverage:
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.