Skip to content

Commit 21fed39

Browse files
authored
Update backtesting.py
1 parent e0b929e commit 21fed39

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

backtesting/backtesting.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -705,8 +705,8 @@ def new_order(self,
705705

706706
if is_long:
707707
if not (sl or -np.inf) <= (limit or stop or self.last_price) <= (tp or np.inf):
708-
raise ValueError(f"Long orders require:' f
709-
"SL ({sl}) < LIMIT ({limit or stop or self.last_price}) < TP ({tp})")
708+
raise ValueError(f"Long orders require:'
709+
f"SL ({sl}) < LIMIT ({limit or stop or self.last_price}) < TP ({tp})")
710710
else:
711711
if not (tp or -np.inf) <= (limit or stop or self.last_price) <= (sl or np.inf):
712712
raise ValueError(f"Short orders require: "

0 commit comments

Comments
 (0)