feat: add ScrubVault DepositVault TVL to scrub project (Kava + Arbitrum)#18679
feat: add ScrubVault DepositVault TVL to scrub project (Kava + Arbitrum)#18679gaspare100 wants to merge 1 commit intoDefiLlama:mainfrom
Conversation
Extends the existing scrub project to track TVL from the ScrubVault DepositVault contracts on Kava and Arbitrum. ScrubVault is a delta-neutral managed vault where users deposit USDt (Kava) or USDC (Arbitrum) and receive share tokens. Capital is deployed off-chain across CEXs and DEXs running a delta-neutral funding-rate strategy. Because funds are actively managed off-chain, the vault contract holds only unprocessed pending deposits. The authoritative AUM figure is the on-chain totalVaultValue variable, updated by the strategy role via distributeRewards() each time PnL is settled back to the vault. TVL here = assets under management. Contracts: - Kava DepositVault 0x7BFf6c730dA681dF03364c955B165576186370Bc (USDt) - Arbitrum DepositVault 0x439a923517C4DFD3F3d0ABb0C36E356D39CF3f9D (USDC)
📝 WalkthroughWalkthroughThis pull request adds TVL computation for ScrubVault smart contracts. It introduces DepositVault contract addresses and corresponding stablecoin assets for KAVA and ARB networks, then implements a Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
projects/scrub/index.js (1)
72-91: Consider adding methodology export for transparency.Since the TVL is based on an admin-updatable
totalVaultValue(AUM from off-chain strategies) rather than on-chain token balances, you may want to add amethodologyfield to document this for users browsing DefiLlama. This helps set expectations that TVL accuracy depends on timely admin updates.// Example: methodology: "ScrubVault TVL is calculated from the on-chain totalVaultValue variable, which represents assets under management deployed off-chain in delta-neutral strategies. This value is updated by the protocol when rewards are distributed."🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@projects/scrub/index.js` around lines 72 - 91, Add a public `methodology` export describing that TVL uses the on-chain `totalVaultValue` AUM (admin-updatable) rather than token balance snapshots; update the module that defines `scrubVaultTvl` so it exports a `methodology` string (alongside the existing `kava` and `arbitrum` tvl entries) that clearly states the TVL source, that it represents off-chain/deployed assets in delta-neutral strategies, and that accuracy depends on admin updates to `totalVaultValue` (reference `scrubVaultTvl`, `totalVaultValue`, `KAVA_DEPOSIT_VAULT`, and `ARB_DEPOSIT_VAULT` to locate the code).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@projects/scrub/index.js`:
- Around line 72-91: Add a public `methodology` export describing that TVL uses
the on-chain `totalVaultValue` AUM (admin-updatable) rather than token balance
snapshots; update the module that defines `scrubVaultTvl` so it exports a
`methodology` string (alongside the existing `kava` and `arbitrum` tvl entries)
that clearly states the TVL source, that it represents off-chain/deployed assets
in delta-neutral strategies, and that accuracy depends on admin updates to
`totalVaultValue` (reference `scrubVaultTvl`, `totalVaultValue`,
`KAVA_DEPOSIT_VAULT`, and `ARB_DEPOSIT_VAULT` to locate the code).
Summary
Extends the existing Scrub project to include TVL from the ScrubVault DepositVault contracts on Kava and Arbitrum.
What is ScrubVault?
ScrubVault is a delta-neutral managed vault where users deposit USDt (Kava) or USDC (Arbitrum) and receive share tokens representing proportional ownership. The deposited capital is deployed off-chain across centralised and decentralised exchanges running a delta-neutral funding-rate and market-making strategy.
Why funds are not sitting in the contract
The vault contract acts as an on-chain accounting and settlement layer. Once a deposit batch is processed, the stablecoins are transferred to the strategy wallet and actively deployed on exchanges. The on-chain
totalVaultValuevariable is the authoritative AUM figure — updated by the strategy role viadistributeRewards()each time PnL is settled back to the vault.TVL reported here reflects assets under management, not tokens sitting in the contract (a
balanceOfcheck would show near-zero).Contracts tracked
0x7BFf6c730dA681dF03364c955B165576186370Bc0x439a923517C4DFD3F3d0ABb0C36E356D39CF3f9DNo double-counting
The DepositVault addresses are not referenced in the existing Scrub or ScrubInvest adapters. The vault holds ~$0 in actual token balance (funds are off-chain), so existing
sumTokenssweeps cannot pick them up.Summary by CodeRabbit