Skip to content

Commit

Permalink
fix(ccxt): type conversion of order limits check
Browse files Browse the repository at this point in the history
  • Loading branch information
kieran-mackle committed Mar 22, 2024
1 parent 1f0b325 commit 0aec641
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion autotrader/brokers/ccxt.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def place_order(self, order: Order, **kwargs) -> None:
# Check order meets limits
limits: dict = self.api.markets.get(order.instrument, {}).get("limits", {})
if limits.get("amount") is not None:
if order.size < limits["amount"]["min"]:
if float(order.size) < float(limits["amount"]["min"]):
# Order too small
self._logger.warning(f"Order below minimum size: {order}")
return None
Expand Down

0 comments on commit 0aec641

Please sign in to comment.