Timestamp keys are incorrectly mapped to numbers instead of datetime-based strings when invalid
leeren opened this issue · 0 comments
leeren commented
When a timestamp-based key has a corresponding value which is unable to be successfully rendered as a valid timestamp (as in the line below), the timestamp is returned as None and later logged in its corresponding dictionary as a Number value.
osxcollector/osxcollector/osxcollector.py
Line 359 in 2581ee5
This can cause type-conflicting issues when further ingesting output JSON data into analytics services such as Elasticsearch. A simple fix is to always have timestamp-based keys return strings corresponding to super early epoch timestamps (e.g. '1970').