MCPcopy Create free account
hub / github.com/danpaquin/coinbasepro-python / __init__

Method __init__

cbpro/order_book.py:16–25  ·  view source on GitHub ↗
(self, product_id='BTC-USD', log_to=None)

Source from the content-addressed store, hash-verified

14
15class OrderBook(object):
16 def __init__(self, product_id='BTC-USD', log_to=None):
17 self._asks = SortedDict()
18 self._bids = SortedDict()
19 self._client = PublicClient()
20 self._sequence = -1
21 self._log_to = log_to
22 if self._log_to:
23 assert hasattr(self._log_to, 'write')
24 self._current_ticker = None
25 self.product_id = product_id
26
27 def reset_book(self):
28 self._asks = SortedDict()

Callers 1

__init__Method · 0.45

Calls 1

PublicClientClass · 0.90

Tested by

no test coverage detected