Skip to content

Commit

Permalink
[Binance] Add adjustForTimeDifference option
Browse files Browse the repository at this point in the history
  • Loading branch information
Herklos committed Aug 29, 2021
1 parent 29d0fb8 commit 82b029c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Trading/Exchange/binance/binance_exchange.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,15 @@ class Binance(exchanges.SpotCCXTExchange):

BINANCE_MARK_PRICE = "markPrice"

BINANCE_CCXT_OPTIONS = {
"timeDifference": 0, # the difference between system clock and Binance clock
"adjustForTimeDifference": False, # controls the adjustment logic upon instantiation
}

def __init__(self, config, exchange_manager):
super().__init__(config, exchange_manager)
self.connector.add_options(self.BINANCE_CCXT_OPTIONS)

@classmethod
def get_name(cls):
return 'binance'
Expand Down

0 comments on commit 82b029c

Please sign in to comment.