docs: clarify nominal interest rate semantics#259
Merged
liobrasil merged 35 commits intoholyfuchs/FLO-18-nominal-interetsfrom Mar 11, 2026
Merged
docs: clarify nominal interest rate semantics#259liobrasil merged 35 commits intoholyfuchs/FLO-18-nominal-interetsfrom
liobrasil merged 35 commits intoholyfuchs/FLO-18-nominal-interetsfrom
Conversation
…dation - fork_multiple_positions_per_user.cdc covering three scenarios: - Multiple positions with distinct collateral types (FLOW, USDF, USDC, WETH, WBTC) and isolation guarantees between them - Cross-position effects through shared liquidity pools - Batch liquidation of 4 positions (2 full, 2 partial) in a single tx
…eates 100 positions across three collateral types (50 USDF, 45 USDC, 5 WBTC), crashes all collateral prices 40% simultaneously, and batch-liquidates all positions via MockDexSwapper in chunks of 10 to stay within computation limits.
…ion-per-user-scenarios-testing # Conflicts: # flow.json
Co-authored-by: patrick <72362902+holyfuchs@users.noreply.github.com>
…on flow.json hash
…testing # Conflicts: # cadence/tests/test_helpers.cdc # flow.json
…o deposit collateral back to liquidator
…ion-per-user-scenarios-testing
Gornutz
requested changes
Mar 10, 2026
…-scenarios-testing Multi-Position Per User Scenarios: Fork Tests & Supporting Infrastructure cadence/tests/fork_multiple_positions_per_user.cdc Runs against mainnet at block 142528994 using real token holders and real token identifiers (FLOW, USDF, USDC, WETH, WBTC). Contains 4 tests: testMultiplePositionsPerUser, testPositionInteractionsSharedLiquidity, testBatchLiquidations, testMassUnhealthyLiquidations
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Co-authored-by: Gornutz <90406700+Gornutz@users.noreply.github.com>
Gornutz
approved these changes
Mar 11, 2026
…-rate-terminology
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
Fixed-Curve Commentary Update
Some of the old comments described the fixed-curve lender-side math too simplistically, implying a relationship like
creditRate = debitRate - insuranceRate.The implementation in
FlowALPModelsdoes not use that simplified formula on the fixed-rate path. Instead, it computes a combined protocol fee factor frominsuranceRate + stabilityFeeRate, then derives the credit rate from the debit rate after applying that combined fee factor.This PR does not change protocol behavior. It only updates comments and documentation so they no longer imply that the spread is driven only by insurance, or that the lender-side rate is computed by a simple subtraction.
Testing