final ohlc bugfix

This commit is contained in:
tim
2024-08-05 02:11:58 -04:00
parent ead9a61480
commit af084e3e5d

View File

@@ -287,10 +287,11 @@ class OHLCFileSeries:
os.makedirs(os.path.dirname(quote_filename), exist_ok=True) os.makedirs(os.path.dirname(quote_filename), exist_ok=True)
self.quote_file = open(quote_filename, 'bw') self.quote_file = open(quote_filename, 'bw')
line = None line = None
try: if line:
start, old_time, old_price = line.split(',') try:
except ValueError: start, old_time, old_price = line.split(',')
line = None except ValueError:
line = None
if line: if line:
# noinspection PyUnboundLocalVariable # noinspection PyUnboundLocalVariable
self.series_start = from_timestamp(int(start)) self.series_start = from_timestamp(int(start))