import re, typing
from struct import pack
-from subprocess import Popen, PIPE
from time import strftime, gmtime
>>> remove(f.name)
"""
- # Open pipe to tai64nlocal: we will write lines of our input (the
- # raw log file) to it, and read log lines with readable timestamps
- # from it.
+ # Open a pipe to tai64nlocal. We'll write lines of our input file
+ # (the log file) to it, and read back the same lines but with
+ # friendly timestamps in them.
+ from subprocess import Popen, PIPE
tai = Popen(["tai64nlocal"], stdin=PIPE, stdout=PIPE, text=True, bufsize=0)
for line in file: