-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposed 2.2.0-rc1 #5003
Merged
Merged
Proposed 2.2.0-rc1 #5003
Conversation
This file contains 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
$ find src/ripple/ src/test/ -type f -exec sed -i 's:include\s*["<]ripple/\(.*\)\.h\(pp\)\?[">]:include <ripple/\1.h>:' {} +
It can be difficult to make transaction breaking changes to low level code because the low level code does not have access to a ledger and the current activated amendments in that ledger (the "rules"). This patch adds global access to the current ledger rules as a `std::optional`. If the optional is not seated, then there is no active transaction.
The AMM has an invariant for swaps where: new_balance_1*new_balance_2 >= old_balance_1*old_balance_2 Due to rounding, this invariant could sometimes be violated (although by very small amounts). This patch introduces an amendment `fixAMMRounding` that changes the rounding to always favor the AMM. Doing this should maintain the invariant. Co-authored-by: Bronek Kozicki Co-authored-by: thejohnfreeman
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## release #5003 +/- ##
=========================================
- Coverage 71.0% 70.9% -0.0%
=========================================
Files 796 796
Lines 66727 66792 +65
Branches 10973 10997 +24
=========================================
+ Hits 47348 47377 +29
- Misses 19379 19415 +36
|
scottschurr
approved these changes
Apr 26, 2024
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.
High Level Overview of Change
This is a release candidate for the 2.2.0 release.
Highlights:
The base branch is
release
. All releases (including betas) go inrelease
. This PR will be merged with--ff-only
(not squashed or rebased, and not using the GitHub UI) to bothrelease
anddevelop
.Context of Change
This introduces
fixAMMRounding
amendment which fixes rounding to better preserve the AMM swap invariantnew_balance_1*new_balance_2 >= old_balance_1*old_balance_2
It also introduces the first step in a physical code reorganization, unit test utilities to test RPC calls, and a global
Rules
object for transaction processing.Type of Change
API Impact
No API impact.