Skip to content

Commit

Permalink
Include timestamp in HPFeeds reporter (#411)
Browse files Browse the repository at this point in the history
* Include timestamp in HPFeeds reporter

* Update log_hpfeeds.py
  • Loading branch information
Chrzi committed Jan 16, 2022
1 parent a98b7ab commit 2fdce2e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tanner/reporting/log_hpfeeds.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import traceback
import json
from datetime import datetime

import tanner.reporting.hpfeeds as hpfeeds

Expand Down Expand Up @@ -27,6 +28,7 @@ def connected(self):
return self.connected_state

def create_session(self, session_data):
session_data["timestamp"] = datetime.utcnow().strftime("%Y-%m-%dT%H:%M:%S.%f")
event_data = json.dumps(session_data)
try:
self.hpc.publish(self.channel, event_data)
Expand Down

0 comments on commit 2fdce2e

Please # to comment.