Commit Graph

15 Commits

Author SHA1 Message Date
pezkuwichain a7d11ce6a2 feat: add APY computation to AH SubQuery, clean relay SubQuery from AH pool logic 2026-02-18 06:00:45 +03:00
pezkuwichain 5447579477 feat: save pool stash active stakers with AH genesis from relay SubQuery 2026-02-18 05:55:05 +03:00
pezkuwichain 9c9c2a132f fix: add 'modl' prefix to pool stash derivation to match Substrate PalletId::into_sub_account_truncating 2026-02-18 05:42:45 +03:00
pezkuwichain c22f9b90e0 fix: convert Uint8Array to hex string for AccountId createType 2026-02-18 05:23:45 +03:00
pezkuwichain 358f13db50 fix: save pool stash accounts with relaychain type for wallet compat
The wallet queries activeStakers with the pool's bonded stash address
and stakingType="relaychain" (unwrapped from nomination-pool). Derive
pool stash accounts from bondedPools and save with correct type.
2026-02-18 05:18:44 +03:00
pezkuwichain 81c6c89bfb fix: read validators from overview to capture all active stakers
Validators with only self-stake (no nominator pages) were missing.
Now reads erasStakersOverview for complete validator list.
2026-02-18 04:50:18 +03:00
pezkuwichain 3dc7a19dee fix: add relay block handler to init active stakers from chain state
The event-based StakersElected handler had a bug where paged exposure
data wasn't properly extracted. Add handleRelayBlock that queries
erasStakersPaged directly from live chain state on first block to
ensure all validators and nominators are captured.
2026-02-18 04:44:57 +03:00
pezkuwichain 7b58fa0e4a feat: add AH GraphQL engine + block handler for pool stakers init
- Add handleBlock to query live chain state for existing pool members
- Add second GraphQL engine container for Asset Hub schema (port 3001)
- Register block handler in pezkuwi-assethub.yaml
2026-02-18 04:07:45 +03:00
pezkuwichain 1c79402d5c feat: track nomination pool members as active stakers
Add handlePoolBonded/handlePoolUnbonded handlers to Asset Hub SubQuery.
When a user bonds to a nomination pool, they are saved as an ActiveStaker
with networkId=AssetHub and stakingType=nomination-pool. This fixes the
wallet showing INACTIVE for HEZ stakers.
2026-02-18 03:14:44 +03:00
pezkuwichain eefae7469d Update genesis hashes and startBlock for mainnet relaunch
- Relay chain: 0xbb4a61ab... -> 0x1aa94987...
- Asset Hub: 0x00d0e1d0... -> 0xe7c15092...
- Reset startBlock to 1 for full re-index from genesis
2026-02-15 22:18:07 +03:00
pezkuwichain 8f051d719a Fix prettier formatting 2026-02-14 04:45:15 +03:00
pezkuwichain 076b54bdc9 Add multi-staking entities, APY calculation, Asset Hub indexer support
- Add StakingApy, ActiveStaker, Reward entities to schema.graphql
- Add APY calculation engine in NewEra.ts (inflation curve + validator commission)
- Add saveMultiStakingReward to Rewards.ts and PoolRewards.ts
- Add handleAssetTransfer for assets.Transferred events
- Add constants.ts with genesis hashes and inflation params
- Add docker-compose.prod.yml for production deployment (relay + assethub nodes)
- Add deploy-vps.yml GitHub Actions workflow for auto-deploy on push
2026-02-14 02:38:22 +03:00
pezkuwichain 0b0519bff8 Add codegen step to security workflow and fix prettier formatting 2026-02-13 01:51:37 +03:00
pezkuwichain 2f1d6dd316 Migrate to native @pezkuwi packages and remove swap integrations
Replace npm aliases (@polkadot -> @pezkuwi) with direct @pezkuwi package
imports. Add tsconfig path mappings to redirect @polkadot type references
from @subql/types to @pezkuwi equivalents, enabling proper type resolution
without installing @polkadot packages. Remove Polkadot ecosystem swap/bridge
integrations (HydraDx, AssetConversion) as they're incompatible with Pezkuwi.
2026-02-13 01:36:52 +03:00
pezkuwichain 0812cf9e7a Initial commit: Pezkuwi SubQuery indexer
- pezkuwi.yaml: Relay chain staking indexer (rewards, slashes, pools, transfers, era info)
- pezkuwi-assethub.yaml: Asset Hub indexer (NominationPools, asset transfers)
- GraphQL schema for staking data entities
- Handler mappings from Nova SubQuery base
2026-02-12 23:55:13 +03:00