BitShares Forum

Main => General Discussion => Topic started by: paliboy on October 03, 2017, 11:09:00 am

Title: Margin call algorithm is too dangerous for shorters
Post by: paliboy on October 03, 2017, 11:09:00 am
Hi, multiple positions were margin-called today and couple of people in Telegram pointed out that when you get margin called, it will try to settle whole postion, not only part that is undercollaterized.

For example this is Stan's HERO position after some part was already bought back:

(https://i.imgur.com/SrCB0Hi.png)

(https://i.imgur.com/Zr0BmI9.png)

The algorithm buys back the asset but the collateral stays the same which leads to ever-increasing collateral ratio, even far beyond maintenance collateral ratio (MCR) which is not behavior that I would expect.

My suggestion would be to change margin call algorithm so that it stop when collateral ratio becomes higher that MCR. In the example above it would mean that the algorithm would stop buying HEROs as soon as the collateral ratio of position would be higher as 200% (MCR of HERO asset).

What do you think, does it make sense? IMHO it would help big holders of smart assets and still keep the system stable.
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: pc on October 03, 2017, 12:09:28 pm
Makes sense.
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: paliboy on October 03, 2017, 12:23:27 pm
Would such a change require a BSIP and/or a hard fork?
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: oldman on October 03, 2017, 01:25:10 pm
I would suggest contacting Bill Butler or opening an issue on github https://github.com/bitshares/bitshares-ui/releases/tag/2.0.171001 (https://github.com/bitshares/bitshares-ui/releases/tag/2.0.171001)

Title: Re: Margin call algorithm is too dangerous for shorters
Post by: pc on October 03, 2017, 03:44:23 pm
Would such a change require a BSIP and/or a hard fork?

Yes, as per policy.

We have several issues pending concerning market rules. IMO we should collect them into one BSIP and solve them all in one go.

https://github.com/bitshares/bitshares-core/issues/132
https://github.com/bitshares/bitshares-core/issues/184
https://github.com/bitshares/bitshares-core/issues/338
https://github.com/bitshares/bitshares-core/issues/342
https://github.com/bitshares/bitshares-core/issues/343

I would suggest contacting Bill Butler or opening an issue on github https://github.com/bitshares/bitshares-ui/releases/tag/2.0.171001 (https://github.com/bitshares/bitshares-ui/releases/tag/2.0.171001)

This is definitely not a UI issue.
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: Chronos on October 03, 2017, 08:34:16 pm
Wow, I was not aware of this. It certainly doesn't match what would be expected. I agree on the proposed fix.
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: paliboy on February 06, 2018, 03:33:58 pm
It's happening again, this time to rit-capital-partners

(https://i.imgur.com/5ZwN2YI.png)
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: abit on February 06, 2018, 05:33:20 pm
New BSIP https://github.com/bitshares/bsips/issues/51
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: Victor118 on February 06, 2018, 06:25:54 pm


The algorithm buys back the asset but the collateral stays the same which leads to ever-increasing collateral ratio, even far beyond maintenance collateral ratio (MCR) which is not behavior that I would expect.


I don't understand , how the collateral can stay the same ?
When someone is margin called the algorithm buys back the asset by selling the collateral, so there is less collateral , no ?
Title: Re: Margin call algorithm is too dangerous for shorters
Post by: paliboy on February 09, 2018, 03:21:20 pm
You are right, the collateral will decrease.

@abit thanks for BSIP link