diff --git a/.gitignore b/.gitignore index 1d46a0d..da767e2 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,9 @@ env-python2/ build/ *.sw* *.egg-info + + +# PB + +.idea/ +cmake*/ diff --git a/Makefile b/Makefile index 9ecc6be..cce361a 100644 --- a/Makefile +++ b/Makefile @@ -8,4 +8,3 @@ bootstrap-python3: bootstrap-python2: virtualenv env-python2 env-python2/bin/pip install -r requirements/base.txt - diff --git a/requirements/base.txt b/requirements/base.txt index 06c7777..c162866 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -1,5 +1,5 @@ pyyaml==5.3.1 -tabulate==0.8.7 +tabulate==0.8.10 requests==2.25.0 ujson==4.0.1 v20==3.0.25.0 diff --git a/src/account/instruments.py b/src/account/instruments.py index 2a8f82f..f9cf5f8 100755 --- a/src/account/instruments.py +++ b/src/account/instruments.py @@ -3,6 +3,7 @@ import argparse import common.config import common.view +import v20 def main(): @@ -35,7 +36,7 @@ def main(): # # Fetch the tradeable instruments for the Account found in the config file # - response = api.account.instruments(account_id) + response: v20.response.Response = api.account.instruments(account_id) # # Extract the list of Instruments from the response. diff --git a/src/account/summary.py b/src/account/summary.py index f180998..1a01eaa 100755 --- a/src/account/summary.py +++ b/src/account/summary.py @@ -2,7 +2,7 @@ import argparse import common.config -from .account import Account +from account import Account def main(): diff --git a/src/pricing/stream.py b/src/pricing/stream.py index e1170f9..b7a2f8f 100755 --- a/src/pricing/stream.py +++ b/src/pricing/stream.py @@ -67,10 +67,12 @@ def main(): # Print out each price as it is received # for msg_type, msg in response.parts(): - if msg_type == "pricing.Heartbeat" and args.show_heartbeats: + if msg_type == "pricing.PricingHeartbeat" and args.show_heartbeats: print(heartbeat_to_string(msg)) - elif msg_type == "pricing.Price": + elif msg_type == "pricing.ClientPrice": print(price_to_string(msg)) + else: + print(f'type {msg_type}, msg {msg}') if __name__ == "__main__":