feat(miner): add --dry-run to the remaining local-mutating CLI commands#5532
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5532 +/- ##
==========================================
+ Coverage 94.87% 94.88% +0.01%
==========================================
Files 568 568
Lines 45055 45161 +106
Branches 14675 14675
==========================================
+ Hits 42746 42852 +106
Misses 1575 1575
Partials 734 734
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
gittensory-ui | e10b1db | Commit Preview URL Branch Preview URL |
Jul 13 2026, 04:17 AM |
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-13 04:28:58 UTC
⏸️ Suggested Action - Manual Review Review summary Nits — 5 non-blocking
Concerns raised — review before merging
📋 Copy for AI agents — paste into your coding agent
Review context
Contributor next steps
Signal definitions
[BETA] Chat with GittensoryAsk Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Extends the --dry-run pattern already added to attempt/loop across the rest of the miner CLI's write paths: claim claim/release, queue next/done/release/ requeue/claim-batch, state set, discover, and orb export. Read-only commands (discover, manage poll) still perform their real GitHub fetch/poll under --dry-run and report what a write would have done via a no-op store stub; pure-write commands short-circuit before opening any store. Advances #4847
60be716 to
e10b1db
Compare
Completes the --dry-run coverage started in #5527/#5532: governor pause/resume (#4851) are the last local-mutating commands in the CLI. Reports what would happen and returns before opening governor-state, matching every other mutating command's dry-run pattern. governor status is read-only and needs no dry-run. Closes #4847
Summary
--dry-runpattern (already shipped forattempt/loopin feat(miner): add --dry-run to attempt and loop #5527) to the rest of the miner CLI's write paths:claim claim/claim release,queue next/done/release/requeue/claim-batch,state set,discover, andorb export.discover) perform the real GitHub fetch/rank under--dry-runand report what would be enqueued via a no-op queue stub, so the output is genuinely useful instead of just echoing args.manage pollperforms the real CI check-run poll under--dry-runand reports what would be recorded, via a no-op event ledger.mkdirSync+CREATE TABLE IF NOT EXISTS).governor pause/governor resume(Build a governor pause/resume control surface #4851, PR feat(miner): build a governor pause/resume control surface #5523) are intentionally NOT covered here — that module isn't onmainyet. A small follow-up will add--dry-runthere once feat(miner): build a governor pause/resume control surface #5523 merges.Advances #4847 (full closure needs this PR + #5527 + the governor-pause follow-up).
Test plan
npx tsc --noEmit --incremental falsenpx vitest run test/unit test/contract(798 files, 15527 tests passed, 2 pre-existing skips)npm run test:coverage(unsharded) — 100% patch coverage (lines + branches) on every changed line in the 6 touchedlib/*.jsfiles, verified againstgit diff --unified=0hunksnpm run docs:drift-check,manifest:drift-check,engine-parity:drift-check,miner:env-reference:checknpm audit --audit-level=moderate— 0 vulnerabilitiesnpm run build(packages/gittensory-miner) —node --checkon all lib filesorigin/main