-
-
Notifications
You must be signed in to change notification settings - Fork 8
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
Reward calculation fix for preprod and preview network #394
Merged
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
Member
satran004
commented
Nov 8, 2024
•
edited
Loading
edited
- Preprod network issue was due to multiple retired pools in an epoch sharing the same reward account. The reward account was receiving payment with only one refund.
- Since the Preview network starts directly from the Alonzo era, adjusted the logic accordingly for reward calculation.
- Fix fee calculation issue in preview for one of the invalid tx where total collateral = null and collateralReturn is set.
Enhanced the logic to correctly identify new epochs when the previous epoch is null, particularly when dealing with the initial block in non-Byron eras. This includes handling scenarios where the previous cursor is a genesis entry, ensuring accurate epoch transitions.
The `findNetworkType` method is now executed automatically after bean initialization. This ensures the network type is set before any other initialization logic in the `init` method.
Updated `cf-rewards` to version 0.14.0 and added `vavr` version 0.10.5 to `libs.versions.toml`.
Refactored `getNetworkConfig` to support custom network configurations based on protocol magic and epoch. Integrated `EraService`, `GenesisConfig`, and `UtxoSnapshotService` to dynamically determine epoch-related parameters and initial reserves.
… network Previously, if the previous era was null, the protocol parameters were not initialized correctly. Now, the code merges Shelley and Alonzo parameters when Alonzo era starts at epoch 0
Implemented a method in PoolStorage and PoolStorageImpl to retrieve retired pools for a given epoch. Updated PoolStatusRepository with a new query to support this functionality. Additionally, modified PoolStateService to handle testnet address conversion logic for non-mainnet networks.
Quality Gate failedFailed conditions See analysis details on SonarCloud Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
Sotatek-HuyLe3a
approved these changes
Nov 11, 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.