[New-bugs-announce] [issue46292] Add microseconds to logging.LogRecord

James Casbon report at bugs.python.org
Fri Jan 7 09:11:50 EST 2022


New submission from James Casbon <casbon+gh at gmail.com>:

LogRecord makes microseconds available via the msecs attribute.  This patch adds microseconds via usecs attribute.

Some regulators (eg MIFID II) require accuracy greater than 1ms in some industries.

This patch calls time_ns rather than time so that the usecs and msecs are calculated from int types and then gets the original ct attribute via division.

----------
files: usecs.patch
keywords: patch
messages: 409963
nosy: jamescasbon
priority: normal
severity: normal
status: open
title: Add microseconds to logging.LogRecord
Added file: https://bugs.python.org/file50546/usecs.patch

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46292>
_______________________________________


More information about the New-bugs-announce mailing list