Skip to content

feat: index user rebate staking for explorer - #24

Merged
mswilkison merged 3 commits into
masterfrom
feat/rebate-staking-subgraph
Oct 4, 2026
Merged

mswilkison merged 3 commits into
masterfrom
feat/rebate-staking-subgraph

Conversation

@mswilkison

@mswilkison mswilkison commented Oct 4, 2026 •

Copy link
Copy Markdown

Explorer currently reads rebate staking and deposit fee waivers from the deprecated custom indexer, whose public endpoint is unavailable. The existing tBTC subgraph has operator staking but lacks the user RebateStaking entities needed to replace those reads.

Adds RebateStaker, RebateStakingEvent, and RebateStakingStats, indexing the mainnet proxy from its actual deployment block (23,598,704). Stake remains in the balance while unstaking is pending; repeated requests replace the pending amount; transfers move the balance and pending request and record both participants. Rebate totals retain the previous API's lifetime award semantics, in satoshis, with cancellations recorded separately. Existing entities and consumers remain compatible.

Consumer migration: tlabs-xyz/threshold-dapp#453, held in draft until the public proxy cutover.

Adds Matchstick regression tests to the reusable mainnet CI/deployment check and documents the coordinated Explorer cutover. Sepolia remains compile-only with the source disabled because no deployment is known.

Validation: Node 22.22.0; codegen; mainnet and Sepolia builds; all 5 mapping tests; all 58 existing cutover/toolchain tests passed locally.

Release order: deploy, fully sync, and publish this subgraph; update threshold-api's production SUBGRAPH_GATEWAY_URL_MAINNET to the verified deployment-pinned gateway; verify the schema, deployment, chain head, and representative balances through the public proxy; then release the dependent Explorer frontend. Preserve the current published deployment throughout re-sync. Creating or merging this PR does not perform that cutover. The custom indexer stays deprecated.

@coderabbitai

coderabbitai Bot commented Oct 4, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 65353de7-7723-4372-9c56-ed7f4e243ed7
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@mswilkison
mswilkison merged commit 95bda3f into master Oct 4, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant