zipline-live / zipline

Zipline-Live, a Pythonic Algorithmic Trading Library
http://www.zipline-live.io/
Apache License 2.0
395 stars 65 forks source link

make broker interface more generic #12

Closed bartosh closed 7 years ago

bartosh commented 7 years ago

Current implementation of --live-trading and --tws-uri command line options is very IB-specific. We need something more generic to be able to support different brokers.

Changed --live-trading and --tws-uri options to more generic --broker and --broker-uri to be able to support more than one broker interface.

Changed the way broker module is imported. From now on it's expected that broker class will be placed into gens/brokers/_broker.py and broker module will be named Broker, e.g. zipline/gens/brokers/ib_broker.py and IBBroker.

This should hopefully allow us to add broker modules without changing command line interface.

Signed-off-by: Ed Bartosh bartosh@gmail.com

tibkiss commented 7 years ago

I don't want to hold this PR back any further, but there is a merge conflict. Ed, could you please resolve the conflicts (or re-create the PR)? Thanks!

coveralls commented 7 years ago

Coverage Status

Coverage increased (+1.0%) to 87.573% when pulling 9f59661da202aae0b677affbb1ae6db7a39b6db4 on ed into fa25a666a192ed479b25a54c43420e1d418bfe5d on live.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+1.0%) to 87.573% when pulling 9f59661da202aae0b677affbb1ae6db7a39b6db4 on ed into fa25a666a192ed479b25a54c43420e1d418bfe5d on live.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+1.0%) to 87.573% when pulling 8736699de12fb6bf2777be81ad25109bade1a40a on ed into fa25a666a192ed479b25a54c43420e1d418bfe5d on live.

tibkiss commented 7 years ago

LGTM, thanks Ed!