Skip to content

Commit

Permalink
Added flake8 to the environment files.
Browse files Browse the repository at this point in the history
  • Loading branch information
martinkou committed Aug 24, 2019
1 parent 0a0e8f8 commit 819c13b
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 7 deletions.
6 changes: 4 additions & 2 deletions .flake8
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
[flake8]
filename = *.py, *.pyx
ignore = E501,E702
ignore = E501,E702,W504
per-file-ignores =
hummingbot/**/*.pyx: E225, E226
hummingbot/**/*.pyx: E225, E226, E999
hummingbot/**/*.pxd: E225, E226, E999
max-line-length = 120
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ cdef class PureMarketMakingStrategyV2(StrategyBase):
self._last_timestamp = 0
self._status_report_interval = status_report_interval


self._filter_delegate = filter_delegate
self._pricing_delegate = pricing_delegate
self._sizing_delegate = sizing_delegate
Expand Down Expand Up @@ -195,7 +194,7 @@ cdef class PureMarketMakingStrategyV2(StrategyBase):
def execute_orders_proposal(self, market_info: MarketSymbolPair, orders_proposal: OrdersProposal):
return self.c_execute_orders_proposal(market_info, orders_proposal)

def cancel_order(self, market_info: MarketSymbolPair, order_id:str):
def cancel_order(self, market_info: MarketSymbolPair, order_id: str):
return self.c_cancel_order(market_info, order_id)

def get_order_price_proposal(self, market_info: MarketSymbolPair) -> PricingProposal:
Expand Down Expand Up @@ -294,8 +293,8 @@ cdef class PureMarketMakingStrategyV2(StrategyBase):
if sizing_proposal.buy_order_sizes[0] > 0 or sizing_proposal.sell_order_sizes[0] > 0:
actions |= ORDER_PROPOSAL_ACTION_CREATE_ORDERS

if ((market_info.market.name not in self.RADAR_RELAY_TYPE_EXCHANGES) or
(market_info.market.name == "bamboo_relay" and market_info.market.use_coordinator)):
if ((market_info.market.name not in self.RADAR_RELAY_TYPE_EXCHANGES) or
(market_info.market.name == "bamboo_relay" and market_info.market.use_coordinator)):
for active_order in active_orders:
# If there are active orders, and active order cancellation is needed, then do the following:
# 1. Check the time to cancel for each order, and see if cancellation should be proposed.
Expand All @@ -316,7 +315,6 @@ cdef class PureMarketMakingStrategyV2(StrategyBase):
sizing_proposal.sell_order_sizes,
cancel_order_ids)


cdef c_did_fill_order(self, object order_filled_event):
cdef:
str order_id = order_filled_event.order_id
Expand Down
1 change: 1 addition & 0 deletions setup/environment-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ dependencies:
- eth-rlp==0.1.2
- eth-typing==2.1.0
- eth-utils==1.4.1
- flake8==3.7.8
- future==0.17.1
- hexbytes==0.1.0
- http://hummingbot-python.s3-website-us-west-2.amazonaws.com/hummingsim-20190729-cp36-cp36m-linux_x86_64.whl
Expand Down
1 change: 1 addition & 0 deletions setup/environment-win64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ dependencies:
- eth-rlp==0.1.2
- eth-typing==2.1.0
- eth-utils==1.6.1
- flake8==3.7.8
- future==0.17.1
- hexbytes==0.2.0
- hyperlink==19.0.0
Expand Down
1 change: 1 addition & 0 deletions setup/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ dependencies:
- eth-rlp==0.1.2
- eth-typing==2.1.0
- eth-utils==1.4.1
- flake8==3.7.8
- hexbytes==0.1.0
- hummingsim==20190724
- hyperlink==18.0.0
Expand Down

0 comments on commit 819c13b

Please sign in to comment.