Skip to content
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

Unable to settle more than total debt amount in individual settlement fund when no sufficient price feeds #2587

Closed
2 of 17 tasks
abitmore opened this issue Feb 6, 2022 · 1 comment · Fixed by #2716
Closed
2 of 17 tasks
Labels
3d Bug Classification indicating the existing implementation does not match the intention of the design hardfork

Comments

@abitmore
Copy link
Member

abitmore commented Feb 6, 2022

Bug Description

If a BitAsset's individual settlement fund is not empty, and there is no sufficient price feeds, it is unable to settle an amount which is greater than the total debt amount in the individual settlement fund. This is due to a lack of a null price check in code

if( HARDFORK_CORE_2481_PASSED( maint_time ) )
{
d.apply_force_settlement( settle, bitasset, *asset_to_settle );
}
which is required in later code
FC_ASSERT( !bitasset.current_feed.settlement_price.is_null(), "Internal error: no sufficient price feeds" );

This is not critical since the BitAsset holders can still request smaller amounts.

Steps To Reproduce

TBD

Expected Behavior

The individual settlement fund normally pays the force settlement request, and the excess amount is returned to the requester.

Host Environment
Please provide details about the host environment. Much of this information can be found running: witness_node --version.

  • BitShares Version: 6.0.1

Impacts
Describe which portion(s) of BitShares Core may be impacted by this bug. Please tick at least one box.

  • API (the application programming interface)
  • Build (the build process or something prior to compiled code)
  • CLI (the command line wallet)
  • Deployment (the deployment process after building such as Docker, Travis, etc.)
  • DEX (the Decentralized EXchange, market engine, etc.)
  • P2P (the peer-to-peer network for transaction/block propagation)
  • Performance (system or user efficiency, etc.)
  • Protocol (the blockchain logic, consensus, validation, etc.)
  • Security (the security of system or user data, etc.)
  • UX (the User Experience)
  • Other (please add below)

CORE TEAM TASK LIST

  • Evaluate / Prioritize Bug Report
  • Refine User Stories / Requirements
  • Define Test Cases
  • Design / Develop Solution
  • Perform QA/Testing
  • Update Documentation
@abitmore
Copy link
Member Author

Fixed by #2716.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3d Bug Classification indicating the existing implementation does not match the intention of the design hardfork
Projects
None yet
1 participant