chain-kpis: add polkadot (DOT native, Asset Hub stables)#1191
Merged
Conversation
Ships live KPIs on /chains/polkadot. DOT price and mcap flow through Mobula. Stables card renders via DefiLlama Asset Hub aggregate. TVL and DEX gauges stay unpublished (relay chain has zero DeFi: parachain TVL lives under Acala, Moonbeam, Hydration). Also guards defillama TVL publish to skip zero values so chains that DefiLlama tracks by name but with an all zero series (Polkadot today) hide the TVL card instead of rendering $0.
Flotapponnier
added a commit
that referenced
this pull request
Jul 16, 2026
…ub) (#1191) (#1192) Ships live KPIs on /chains/polkadot. DOT price and mcap flow through Mobula. Stables card renders via DefiLlama Asset Hub aggregate. TVL and DEX gauges stay unpublished (relay chain has zero DeFi: parachain TVL lives under Acala, Moonbeam, Hydration). Also guards defillama TVL publish to skip zero values so chains that DefiLlama tracks by name but with an all zero series (Polkadot today) hide the TVL card instead of rendering $0. Co-authored-by: Florent Tapponnier <contact@mobula.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds Polkadot to the chain-kpis harness registry so
/chains/polkadotrenders a live KPI strip like every other chain page. Also guards the DefiLlama TVL publish to skip zero values.Behavior
Cards that render on
/chains/polkadotafter this ships:stablecoincharts/Polkadot)market/data?symbol=DOT)Cards intentionally hidden:
if tvl > 0guard indefillama.gokeeps the gauge unpublished so the card hides instead of rendering "$0"./overview/dexs/Polkadotreturns 500, gauge stays unpublished on error, card hides.polkadottoDEFILLAMA_CHAIN_NAMEinsrc/lib/chain-kpis.tsfor the same zero series reason; chart hides gracefully.Files
harnesses/chain-kpis/cmd/script/registry.go: append polkadot entryharnesses/chain-kpis/cmd/script/defillama.go: guard TVL publish on> 0The TVL guard is a general QoL fix. Any chain that DefiLlama tracks by name but with a legitimately zero TVL series will now hide the card instead of surfacing a broken looking "$0".
Test plan
go build ./...passeschain_native_price_usd{chain="polkadot", symbol="DOT"}andchain_native_mcap_usd{chain="polkadot"}publishchain_stables_mcap_usd{chain="polkadot"}publishes with the Asset Hub aggregatechain_tvl_usd{chain="polkadot"}stays absent (zero guard)/chains/polkadotrenders 3 cards (Stables, DOT price, DOT mcap)