feat(miner-manage): add optional anonymized Orb telemetry export for miner outcomes (#4277) - #4476
feat(miner-manage): add optional anonymized Orb telemetry export for miner outcomes (#4277)#4476andriypolanski wants to merge 3 commits into
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Caution 🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥 🛑 Gittensory review result - reject/close recommendedReview updated: 2026-07-09 21:33:43 UTC
🛑 Suggested Action - Reject/Close
Why this is blocked
Linked issue satisfactionAddressed 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 #4476 +/- ##
=======================================
Coverage 94.03% 94.03%
=======================================
Files 420 420
Lines 37521 37521
Branches 13701 13701
=======================================
Hits 35282 35282
Misses 1583 1583
Partials 656 656 🚀 New features to boost your workflow:
|
|
Gittensory is closing this pull request on the maintainer's behalf (Linked issue overlaps another open PR; duplicate of another open PR). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed. |
|
Hi @JSONbored, I submitted this PR earlier than #4479, but it is closed by using the draft functionality. If that’s the reason it wasn’t recognized, I think ORB may need to be updated to handle this case properly. |
Closes #4277
Summary
packages/gittensory-miner/lib/orb-export.js: opt-in (default OFF) exporter that reads miner-localpr_outcomeevents from the injected event ledger viareadEvents({ since }), HMAC-anonymizes repo/PR identifiers with a dedicated per-miner secret persisted in local SQLite, buckets rejection reasons with the same taxonomy assrc/selfhost/orb-collector.ts, and POSTs signed batches to the hosted Orb collector.x-orb-signature,x-orb-instance) and the no-PII contract (verdict/outcome/bucketed reason/cycle time only — no diffs, code, logins, or SHAs).ORB_AIR_GAPfor air-gapped deployments; enable viaGITTENSORY_MINER_ORB_EXPORT=1orconfig.orbExport === true.Depends on the sibling #4274
pr-outcome.jswriter (already on main) as the export source.Scope
sincepatternbucketReasonCodetaxonomy (ported verbatim from orb-collector)fetchFnunit tests (no real network)Test plan
test/unit/miner-orb-export.test.ts— opt-in / air-gap gating, anonymization (no plaintext repo/PR in payload), cursor advancement, fetch failure does not advance cursornpm run build:minernpm run test:cigreennpm audit --audit-level=moderatecleanValidation
Changed files
packages/gittensory-miner/lib/orb-export.jspackages/gittensory-miner/lib/orb-export.d.tspackages/gittensory-miner/package.jsontest/unit/miner-orb-export.test.tsEnv / config
GITTENSORY_MINER_ORB_EXPORT=1ORB_AIR_GAP=trueORB_ANONYMIZE=trueORB_COLLECTOR_URLORB_COLLECTOR_TOKENGITTENSORY_MINER_ORB_EXPORT_STATE_DBGITTENSORY_MINER_CONFIG_DIRconfig.orbExport === trueNotes
gate_verdict/ cycle time (no local gate_decision stream yet) — payload still matches the collector's fleet event shape with nulls where unknown.exportMinerOrbBatch()into the miner loop / CLI is follow-up; this PR delivers the library primitive and tests per issue deliverables.bucketReasonCodeinto@jsonbored/gittensory-engineso self-host and miner import one module (currently ported verbatim with sync comment).