Skip to content

Commit 68e8357

Browse files
committed
refactor(scripts): streamline wallet-operator-mapper utilities
Remove single-purpose investigation scripts and add general-purpose query utilities for ongoing operator management. Removed: - calculate-all-beta-staker-weights.js (governance task complete) - calculate-allowlist-weights.js (superseded) - generate-allowlist-weights-final.js (output saved) - check-current-pool-weights.js (investigation complete) - check-sortition-pool-divisor.js (findings incorporated) - investigate-unknown-operator.js (one-time investigation) - verify-missing-wallets.js (specific verification done) Added utility scripts: - query-proof-of-funds.js: Generate proof-of-funds reports - query-sortition-pool.js: Check operator pool status - query-all-pool-operators.js: Discover all pool operators - query-all-stakers.js: Verify staker documentation completeness Updated README to document all remaining scripts in Main and Utility sections.
1 parent d66b34c commit 68e8357

File tree

6 files changed

+1078
-23
lines changed

6 files changed

+1078
-23
lines changed

scripts/wallet-operator-mapper/README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,30 @@ Verifies operator list completeness against CSV data.
7676
- **Purpose**: Data quality checks
7777
- **Usage**: Optional validation step
7878

79+
## Utility Scripts
80+
81+
### query-proof-of-funds.js
82+
Queries ALL tBTC wallets from Bridge contract and their Bitcoin balances.
83+
- **Requirements**: Archive node RPC + internet (uses mempool.space API)
84+
- **Runtime**: Several minutes (rate-limited Bitcoin API calls)
85+
- **Output**: JSON with wallet PKHs, Bitcoin addresses, and balances
86+
- **Usage**: Generate proof-of-funds reports for audits
87+
88+
### query-sortition-pool.js
89+
Checks operators from `operators.json` against sortition pool status.
90+
- **Output**: `sortition-pool-operators.json`
91+
- **Usage**: Verify which operators are active in the pool
92+
93+
### query-all-pool-operators.js
94+
Discovers ALL operators in sortition pool by iterating member IDs.
95+
- **Output**: `pool-operators-complete.json`
96+
- **Usage**: Find operators not in our known list (completeness check)
97+
98+
### query-all-stakers.js
99+
Queries all stakers from TokenStaking contract events.
100+
- **Runtime**: ~1 minute (queries historical events)
101+
- **Usage**: Verify completeness of staker documentation
102+
79103
## Configuration Files
80104

81105
### operators.json ⭐ CRITICAL

0 commit comments

Comments
 (0)