Heartbeat log unit size are not user-friendly
In the file
tor-0.4.5.6/src/feature/dirclient/dirclient.c, at lines 2002-2005, the heartbeat log message shows different amount of data in bytes.
[XXX 00 00:00:00.000] [notice] While not bootstrapping, fetched this many bytes: XXXXXXXXX (server descriptor fetch); XXXXXX (server descriptor upload); XXXXXXXX (consensus network-status fetch); XXXX (authority cert fetch); XXXXX (microdescriptor fetch)
Knowing that my server fetch XXXXXXXXX bytes from the server directory does not really help me to easily understand my bandwidth usage. It could be more nice to look at if each amount of data will be followed by a appropriate unit size. For exemple:
[Time] [notice] While not bootstrapping, fetched this many data: XX.X
MiB(server descriptor fetch); XX.X
KiB(server descriptor upload); XX.X
MiB(consensus network-status fetch); X.X
KiB(authority cert fetch); XXX.X
And like it is said in the description of the file
core/or/status.c, from line 4 to 13:
[...] heartbeat log messages, [...] inform users and operators about basic facts to do with their Tor instance. [...] It collects data [...] and logs it in a human-readable format.