Skip to content

Commit

Permalink
fixed flake8 finding
Browse files Browse the repository at this point in the history
  • Loading branch information
jbaron committed Feb 21, 2024
1 parent 07667bb commit df03654
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .flake8
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[flake8]
max-line-length = 127
max-line-length = 127
per-file-ignores =
# imported but unused
__init__.py: F401
3 changes: 0 additions & 3 deletions roboquant/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

__version__ = "0.2.1"

from .account import Account, OptionAccount, Position
Expand Down Expand Up @@ -34,5 +33,3 @@
EventChannel,
feedutil,
)


6 changes: 3 additions & 3 deletions tests/unit/test_candlestrategy.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@


class _MyStrategy(CandleStrategy):
"""Example using talib to create a strategy"""
"""Example using CandleStrategy to create a custom strategy"""

def _create_signal(self, _, ohlcv: OHLCVBuffer) -> Signal | None:
def _create_signal(self, symbol, ohlcv: OHLCVBuffer) -> Signal | None:
close = ohlcv.close()
sma12 = close[-12:].mean()
sma26 = close[-26:].mean() # type: ignore
sma26 = close[-26:].mean()
if sma12 > sma26:
return Signal.buy()
if sma12 < sma26:
Expand Down

0 comments on commit df03654

Please sign in to comment.