Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions preprocessing/preprocessing.py
Original file line number Diff line number Diff line change
Expand Up @@ -635,14 +635,16 @@ def extract_ts(self, log, rbr, timezone_dict, master_timestamp_list, master_form
"""
ts = None
future_flag = False
timestamp, ts, future_flag = self.master_datetime_extractor(log, timezone_dict, master_timestamp_list, master_format_list)
if not ts:
timestamp, ts, future_flag = self.aql_datetime_extractor(log, rbr, timezone_dict)

if not future_flag:
return timestamp, ts

return None, None
try:
timestamp, ts, future_flag = self.master_datetime_extractor(log, timezone_dict, master_timestamp_list, master_format_list)
if not ts:
timestamp, ts, future_flag = self.aql_datetime_extractor(log, rbr, timezone_dict)

if not future_flag:
return timestamp, ts
except Exception as e:
print(f"Error extracting timestamp \nLogline: {log} \nError: {e}")
return None, None

def process_fn(self, log, timezone_dict, master_timestamp_list, master_format_list):
"""
Expand Down