Skip to content

Commit

Permalink
Add attribute retries in __init__
Browse files Browse the repository at this point in the history
  • Loading branch information
quantitative-technologies committed Aug 16, 2023
1 parent e9c9c87 commit 3f1ab37
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tradingbot/binancefutures.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ def __init__(self, api_key, api_secret, symbol='btcusdt', testnet=True, orderIDP
self.orderIDPrefix = orderIDPrefix
self.last_price = 0
self.open_orders_ws = {}
self.retries = 0 # initialize counter

def open_orders_active(self):
return {order_id: order for order_id, order in self.open_orders_ws.items() if order['status'] in ['PENDING_NEW', 'NEW', 'PARTIALLY_FILLED']}
Expand Down

0 comments on commit 3f1ab37

Please sign in to comment.