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

Alternative black swan response methods #2467

Closed
2 of 17 tasks
abitmore opened this issue May 22, 2021 · 3 comments · Fixed by #2499
Closed
2 of 17 tasks

Alternative black swan response methods #2467

abitmore opened this issue May 22, 2021 · 3 comments · Fixed by #2499
Assignees
Labels

Comments

@abitmore
Copy link
Member

abitmore commented May 22, 2021

User Story

As a MPA owner I'd like to have alternative black swan response methods, but not only global settlement. Specifically, I'd like a method to not liquidate the well-managed debt positions.

A related discussion and analysis is here: bitshares/bsips#179 (comment)

Specification

  • New black_swan_response_method field in extensions of bitasset options (unavailable for PM)
    • global_settlement
    • no_settlement aka "Global Settlement Protection"
      • new median_feed field in asset_bitasset_data_object to track the median of real price feeds
    • individual_settlement_to_fund
      • new individual_settlement_debt and individual_settlement_fund fields in asset_bitasset_data_object
    • individual_settlement_to_order
      • new bool field is_settled_debt field in limit_order_object
  • New disable_bsrm_update bit in asset issuer_permissions (unavailable for PM or UIA)
    • the bit can not be configured in asset flags
  • Update return value of asset_settle_operation to extendable_operation_result

Impacts
Describe which portion(s) of BitShares Core may be impacted by your request. 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 Feature Request
  • Refine User Stories / Requirements
  • Define Test Cases
  • Design / Develop Solution
  • Perform QA/Testing
  • Update Documentation
@abitmore abitmore self-assigned this Aug 6, 2021
@abitmore abitmore linked a pull request Aug 17, 2021 that will close this issue
58 tasks
@abitmore abitmore changed the title Alternative bad debt settlement methods Alternative black swan response methods Aug 26, 2021
@abitmore
Copy link
Member Author

Done via #2499.

@sschiessl-bcp
Copy link

Any chances that example tx payloads are shown somewhere that include setting those new options?

@abitmore
Copy link
Member Author

@sschiessl-bcp see testnet block No. 51348389 which includes an asset_update_bitasset_operation

      "operations": [[
          12,{
            "fee": {
              "amount": 100, 
              "asset_id": "1.3.0"
            },
            "issuer": "1.2.25530",
            "asset_to_update": "1.3.1696",
            "new_options": {
              "feed_lifetime_sec": 864000,
              "minimum_feeds": 1,
              "force_settlement_delay_sec": 86400,
              "force_settlement_offset_percent": 10,
              "maximum_force_settlement_volume": 5,
              "short_backing_asset": "1.3.1602",
              "extensions": {
                "margin_call_fee_ratio": 10,
                "black_swan_response_method": 2
              } 
            },
            "extensions": []
          } 
        ] 
      ],

Signed with cli_wallet command

update_bitasset XBTAAA.USD1 {"short_backing_asset": "1.3.1602", "feed_lifetime_sec": 864000, "force_settlement_offset_percent": 10, "maximum_force_settlement_volume": 5, "minimum_feeds":1, "extensions":{"margin_call_fee_ratio":10, "black_swan_response_method":2}} true

For the bit in asset issuer permission, it's 0x4000 or in decimal format "issuer_permissions": 16384, see the code:

disable_bsrm_update = 0x4000, ///< the bitasset owner can not update BSRM, permission only

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants