feat(miner): add local claims ledger CLI#3314
Conversation
Expose list, claim, release, and sweep subcommands for the existing local claim ledger so operators can manage soft claims without importing store modules directly. Co-authored-by: Cursor <cursoragent@cursor.com>
|
🚨 Contributor flagged. Click here for more info: Superagent Dashboard |
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-05 06:51:10 UTC
⏸️ Suggested Action - Manual Review
Review summary Nits — 7 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 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.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3314 +/- ##
=======================================
Coverage 93.73% 93.73%
=======================================
Files 276 276
Lines 30381 30381
Branches 11073 11073
=======================================
Hits 28479 28479
Misses 1257 1257
Partials 645 645 🚀 New features to boost your workflow:
|
Summary
Adds an operator-facing
gittensory-miner claimsCLI for the existing local soft-claim ledger. The SQLite store (claim-ledger.js) and expiry helper (claim-ledger-expiry.js) already existed, but unlikeledger,governor, andplanthere was no command-line surface to list, record, release, or sweep claims from a laptop.New subcommands:
claims list [--repo <owner/repo>] [--status active|released|expired] [--json]claims claim <owner/repo> <issue#> [--note <text>] [--json]claims release <owner/repo> <issue#> [--json]claims sweep [--max-age-days <n>] [--json]Commands dispatch before the npm update check (offline/local, same as
ledger/governor).No upstream issue was filed:
jony376lacksCreateIssuepermission on this repository. This PR is self-contained against that gap.Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
git diff --checknpm run typechecknpx vitest run test/unit/miner-claim-ledger-cli.test.ts(9/9 passed)npm --workspace @jsonbored/gittensory-miner run buildnpm run test:coveragelocally;codecov/patchrequires ≥99% coverage of the lines AND branches you changed (aim for 100% on your diff so CI variance does not fail near the threshold). Global coverage is a non-blocking trend with a loose 90% backstop, not the gate.npm run test:workersnpm run build:mcpnpm run test:mcp-packnpm run ui:openapi:checknpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
Safety
UI Evidencesection below with JPG/JPEG or PNG screenshots arranged as organized, captioned, clickable thumbnails. SVG screenshots are not used as review evidence. Review-only screenshots or recordings are not committed to the repository.UI Evidence
Not applicable — miner CLI only.
Notes
releaseis idempotent for already-released rows; missing/non-active releases fail closed withclaim_not_found_or_not_active.hooks checkentry and all prior commands.Made with Cursor