Explorar el Código

- Improves the human-readable output in the label file

Patrick Jattke hace 8 años
padre
commit
9e9fe28404
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      code/ID2TLib/LabelManager.py

+ 1 - 1
code/ID2TLib/LabelManager.py

@@ -76,7 +76,7 @@ class LabelManager:
 
             # add timestamp in human-readable format
             timestamp_hr = doc.createElement(self.TAG_TIMESTAMP_HR)
-            timestamp_hr_text = datetime.fromtimestamp(int(timestamp_entry)).strftime('%Y-%m-%d %H:%M:%S')
+            timestamp_hr_text = datetime.fromtimestamp(timestamp_entry).strftime('%Y-%m-%d %H:%M:%S.%f')
             timestamp_hr.appendChild(doc.createTextNode(timestamp_hr_text))
             timestamp_root.appendChild(timestamp_hr)