-
Notifications
You must be signed in to change notification settings - Fork 981
Open
Labels
Description
Describe the bug
The add_horizontal_line_to_candle_chart method does not accept line_style='dashed' as a valid parameter, even though it is listed as a valid option in the documentation. Using this parameter results in a ValueError.
The dotted line style works as expected, but dashed fails with the following traceback:
File "/jesse-docker/jesse/strategies/Strategy.py", line 103, in add_horizontal_line_to_candle_chart
raise ValueError(f"Invalid line_style: {line_style}")
ValueError: Invalid line_style: dashed
To Reproduce
Steps to reproduce the behavior:
def after(self) -> None:
# This line causes the error
self.add_horizontal_line_to_candle_chart('MSS Level', self.mss_level, 'blue', line_style='dashed')
# This line works correctly
# self.add_horizontal_line_to_candle_chart('MSS Level', self.mss_level, 'blue', line_style='dotted')
Expected behavior
The backtest should complete without errors, and the generated interactive chart should display a dashed line
Screenshots
Environment (please complete the following information):
- OS: Docker
- Version: 1.10.8
- python 3.11