Edward O'Callaghan submitted this change.

View Change


Approvals: build bot (Jenkins): Verified Edward O'Callaghan: Looks good to me, approved
flashrom_tester: Change timestamp to UTC microsecond

Match the timestamp with dmesg and other logs for ease of comparing.

BUG=b:246250254
BRANCH=None
TEST=flashrom_tester --libflashrom host

Change-Id: I05182f52c0e9392a4fa2b388fdc30633e5d6e5ef
Signed-off-by: Evan Benn <evanbenn@chromium.org>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/69269
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
---
M util/flashrom_tester/src/logger.rs
1 file changed, 21 insertions(+), 2 deletions(-)

diff --git a/util/flashrom_tester/src/logger.rs b/util/flashrom_tester/src/logger.rs
index 12e5495..3c9b74b 100644
--- a/util/flashrom_tester/src/logger.rs
+++ b/util/flashrom_tester/src/logger.rs
@@ -58,8 +58,8 @@

fn log(&self, record: &log::Record) {
fn log_internal<W: Write>(mut w: W, record: &log::Record) -> std::io::Result<()> {
- let now = chrono::Local::now();
- write!(w, "{}{} ", types::MAGENTA, now.format("%Y-%m-%dT%H:%M:%S"))?;
+ let now = chrono::Utc::now().to_rfc3339_opts(chrono::SecondsFormat::Micros, true);
+ write!(w, "{}{} ", types::MAGENTA, now)?;
write!(
w,
"{}[ {} ]{} ",

To view, visit change 69269. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I05182f52c0e9392a4fa2b388fdc30633e5d6e5ef
Gerrit-Change-Number: 69269
Gerrit-PatchSet: 3
Gerrit-Owner: Evan Benn <evanbenn@google.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-MessageType: merged