Merging updates from defillama#3
Open
iagoLD wants to merge 6380 commits into
Open
Conversation
add isIntrinsicSource
* fix jup lend remove staking apy * remove comments
* feat: add lite usd vault and refactor fluid-lite adaptor * chore: remove pkg lock changes
* refactor to use onchain instead of broken subgraph * parallelized fetch, and use new pool url structure * remove 0 fallbacks
* hyperswap subgraph * add 7d volume
* feat: add accountable on Citrea * fix: address coderabbit comments * address comments * fix: tvlUsd uses stats.totalAssets
* hyperswap-v2 subgraph * remove comments
* expose chainfip lending pools
* Trigger Build
* add guard
* remove lock
* revert lockfile
* address comments
* fix(chainflip): match new API pool keys and emit apyBase
- Filter lending pools by `-chainflip-lending` suffix (API renamed
from `lending-pool`); the previous `.includes('lending-pool')`
matched zero rows so the adapter emitted nothing.
- Read `tokenContractAddress` (current API field) instead of
`tokenAddress`, restoring real ERC-20 addresses for USDC/USDT.
- Rename `apy` to `apyBase` since these are intrinsic, non-reward yields.
- Update Pool type literals to reflect the new pool key format.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: kr3p <123127490+0xkr3p@users.noreply.github.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Attach rewardTokens to the Solana branch when rewardYield > 0, mirroring the EVM pattern. Without it, the test suite's apyReward → rewardTokens invariant strips the yoSOL reward APY.
* feat: Added landing percent to APY calculation * fix: Default values for percent fields --------- Co-authored-by: georgeorl <smmiz.prime@gmail.com>
* improve accuracy for token / rewards / underlying * additional chain support * update readme
* feat: add gmtrade yield adapter * fix: change code based o comments * feat: add underlyingtoken * fix(gmtrade): dedupe identical long/short tokens in underlyingTokens Single-asset markets (e.g. XPD-USDC, WTI-USDC) return the same address for both long_token and short_token; collapsing the array via Set avoids emitting duplicate underlyingTokens while leaving real LP pairs intact. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: kr3p <123127490+0xkr3p@users.noreply.github.com> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* add ample * use realised prize apy * remove intrinsic source * optimise * coderabbit fix
* Add Gami Labs yield adapter * Add apyBase: 0 to pass validator, rename Coinshift Leveraged USPC * Re-trigger CI * Use 30d apyBase as primary, fix Silo V2 via totalAssets/totalSupply ratio * Drop apyBase30d from pool output (use internally only for apyBase fallback) * Fix Spectra USDC Vault
add borrowToken where missing
* feat: add Brix wiTRY yield adapter
Adds a yield adapter for wiTRY, the yield-bearing staking wrapper for
Brix's iTRY (a TRY-pegged stablecoin backed by Turkish money market
funds).
APY is computed entirely on-chain, anchored to actual yield-distribution
events rather than fixed-window block sampling:
1. Collect RewardsReceived events from the wiTRY vault (last 21d)
2. end_event = latest distribution
start_event = latest event with ts <= end_event.ts - 7d
3. Sample convertToAssets at (event.ts + getVestingPeriod()) so each
anchor event's distribution is fully reflected — vesting-aware
4. elapsedDays dynamic (typically 7-9)
5. APY = (rateEnd / rateStart) ^ (365 / elapsedDays) - 1
This is robust to multi-day distribution gaps (Turkish public holidays,
weekends) — both anchors freeze symmetrically when no new distribution
arrives, so the displayed APY stays flat through dry periods and the
catch-up distribution at the end of a gap is absorbed without a spike.
The 10% performance fee is deducted by YieldForwarder before yield is
streamed into the wiTRY vault, so convertToAssets growth already
reflects net yield — no fee multiplier needed.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
* address review: null apyBase fallback, add pricePerShare
- use null instead of 0 for the <2-events fallback so the empty case
is not ingested into the time-series and doesn't skew smoothing
- add pricePerShare (current convertToAssets(1e18) at latest block)
to the pool object
* add isIntrinsicSource field
---------
Co-authored-by: İsmail Emin Erdoğdu <ismailemin@192.168.1.101>
Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Co-authored-by: ismailemin <ismail@inverter.network>
Co-authored-by: kr3p <123127490+0xkr3p@users.noreply.github.com>
…and-tvl accountable: add ethereum support and use API TVL
* Add ForgeYields adaptor (fyETH, fyUSDC, fyWBTC on Ethereum and Starknet) * Add per-strategy URL and searchTokenOverride to ForgeYields adaptor * Use projected APY and remove apyBase7d from ForgeYields adaptor * forgeyields: compute APR/TVL onchain, fix per-chain TVL, add apyBase7d - TVL pulled per-chain via the onchain totalAssets providers (0x5d77...DD6 on Ethereum, 0x2d0e...78b8 on Starknet), USD-converted through coins.llama.fi. Fixes double-count across gateways. - APR computed onchain by sampling convertToAssets(1e18) on the Ethereum gateway at now, now-1d-1h, now-7d-1h and annualizing over the actual elapsed time. Same APR reused for the Starknet pool of the same strategy (same vault logic). - Add apyBase7d (per reviewer request). - 1h safety margin on lookback windows to stay past the previous daily report regardless of its ~10min slack. * forgeyields: add public Starknet RPC fallback for PR CI PR test workflow does not expose STARKNET_RPC (only the prod cron does), so onchain Starknet calls silently failed and dropped half the pools in CI output. Fall back to a public RPC when the env var is missing; prod behavior is unchanged. * forgeyields: document the 25h lookback offset invariant Expand the REPORT_MARGIN comment to spell out why we sample at now-25h (not now-24h), so a future maintainer doesn't read it as a typo and "correct" it back, collapsing APY to ~0. Per reviewer request.
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.
No description provided.