Skip to content
Snippets Groups Projects
Commit 368b329d authored by Jake Taylor's avatar Jake Taylor
Browse files

add better timestamps to e2eReport.py

parent 5b802273
Branches
No related tags found
1 merge request!4Release
......@@ -52,7 +52,10 @@ def main():
messages_sent[sent_message] = {"sender": os.path.basename(path)}
# Capture message timestamp
sent_timestamp_str = re.findall('INFO (.{19})', line)[0]
sent_timestamp_str = re.findall('INFO (.{19}\.{0,1}\d{0,6})', line)[0]
try:
sent_timestamp = datetime.datetime.strptime(sent_timestamp_str, '%Y/%m/%d %H:%M:%S.%f')
except ValueError:
sent_timestamp = datetime.datetime.strptime(sent_timestamp_str, '%Y/%m/%d %H:%M:%S')
log.debug("Located sent timestamp: {}".format(sent_timestamp))
messages_sent[sent_message]["sent"] = sent_timestamp
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment