-
Notifications
You must be signed in to change notification settings - Fork 72
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
[Exchanges] support spot stop losses #1396
Conversation
trading_enums.ExchangeTypes.SPOT.value: { | ||
# order that should be self-managed by OctoBot | ||
trading_enums.ExchangeSupportedElements.UNSUPPORTED_ORDERS.value: [ | ||
# trading_enums.TraderOrderType.STOP_LOSS, # supported on spot (as spot limit) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we also allow stop loss limit as it is supported?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
stop_price = price | ||
price = float(decimal.Decimal(str(price)) * self.STOP_LIMIT_ORDER_INSTANT_FILL_PRICE_RATIO) | ||
# use limit stop loss with a "normally instantly" filled price | ||
return await self._create_limit_stop_loss_order(symbol, quantity, price, stop_price, side, params=params) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
up to use _create_limit_stop_loss_order
No description provided.