Skip to content

[VPD-1168]: Add BNB Core deprecation interest rate model#682

Open
Debugger022 wants to merge 2 commits into
developfrom
feat/VPD-1168
Open

[VPD-1168]: Add BNB Core deprecation interest rate model#682
Debugger022 wants to merge 2 commits into
developfrom
feat/VPD-1168

Conversation

@Debugger022

Copy link
Copy Markdown
Contributor

Summary

  • Adds the Phase-4 market-deprecation "push-out" interest rate model for the BNB Core (legacy) pool: flat 300% borrow rate below the 45% kink, ramping to a 500% maximum at full utilization, to make borrowing non-competitive and migrate positions off the deprecated markets.
  • A dedicated legacy JumpRateModel is required (not the isolated-pools JumpRateModelV2) because BNB Core's legacy VBep20 markets call a 3-arg getBorrowRate / 4-arg getSupplyRate ABI; the isolated-pools model exposes a badDebt-aware ABI those markets cannot call. Repointing to it would brick interest accrual.
  • The model is deploy-only here; the downstream VIP repoints the deprecated BNB Core markets via _setInterestRateModel.

Changes

  • deploy/019-bnbcore-deprecation-irm.ts: hardhat-deploy script for the legacy JumpRateModel. Args base 300% / slope1 0% / jump 363.64% / kink 0.45, BSC blocksPerYear 70,080,000. Gated to bscmainnet/bsctestnet, skipIfAlreadyDeployed, tag BNBCoreDeprecationIRM, with explorer verification on live networks.
  • deployments/bscmainnet/JumpRateModel_base30000bps_slope0bps_jump36364bps_kink4500bps_bpy70080000.json: deployment artifact (deployed at 0xc255352947ef3594C45b0Fe8bcB690e51C3D744A).

Deploy a legacy JumpRateModel (300% flat below the 45% kink, 500% max)
for the BNB Core pool's Phase-4 market deprecation. A separate legacy
contract is required because the isolated-pools JumpRateModelV2 uses a
badDebt-aware getBorrowRate/getSupplyRate ABI that legacy VBep20 markets
cannot call. The downstream VIP repoints the deprecated markets via
_setInterestRateModel.
@Debugger022 Debugger022 self-assigned this Jun 16, 2026
@github-actions

Copy link
Copy Markdown

Code Coverage

Package Line Rate Branch Rate Health
contracts 100% 100%
contracts.Admin 88% 41%
contracts.Comptroller 100% 90%
contracts.Comptroller.Diamond 95% 64%
contracts.Comptroller.Diamond.facets 87% 73%
contracts.Comptroller.Diamond.interfaces 100% 100%
contracts.Comptroller.Types 100% 100%
contracts.Comptroller.legacy 100% 100%
contracts.Comptroller.legacy.Diamond 0% 0%
contracts.Comptroller.legacy.Diamond.facets 0% 0%
contracts.Comptroller.legacy.Diamond.interfaces 100% 100%
contracts.DelegateBorrowers 100% 89%
contracts.FlashLoan.interfaces 100% 100%
contracts.Governance 68% 45%
contracts.InterestRateModels 74% 59%
contracts.Lens 43% 46%
contracts.Liquidator 83% 60%
contracts.Oracle 100% 100%
contracts.PegStability 88% 84%
contracts.Swap 87% 58%
contracts.Swap.interfaces 100% 100%
contracts.Swap.lib 81% 55%
contracts.Tokens 100% 100%
contracts.Tokens.Prime 97% 73%
contracts.Tokens.Prime.Interfaces 100% 100%
contracts.Tokens.Prime.libs 90% 76%
contracts.Tokens.VAI 82% 52%
contracts.Tokens.VRT 20% 9%
contracts.Tokens.VTokens 70% 52%
contracts.Tokens.VTokens.legacy 0% 0%
contracts.Tokens.VTokens.legacy.Utils 0% 0%
contracts.Tokens.XVS 19% 8%
contracts.Tokens.test 100% 100%
contracts.Utils 52% 31%
contracts.VAIVault 50% 45%
contracts.VRTVault 49% 36%
contracts.XVSVault 63% 50%
contracts.external 100% 100%
contracts.lib 89% 71%
Summary 57% (3740 / 6546) 43% (1412 / 3276)

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