interactive: correctly load non-ascii logs
Some packages write utf-8 in logs, and may write build logs in other charset. Now we can load such logs more or less correctly.
This commit is contained in:
parent
7a656153fc
commit
530010dee9
@ -188,7 +188,7 @@ def fti(num, to=print):
|
||||
def logs(num, idx=-1, to=pager):
|
||||
log_file = m_logs.task_event_logs(get_task(num, TASKS))[idx]
|
||||
with open(log_file, 'r') as f:
|
||||
log = f.read()
|
||||
log = f.read().decode('utf-8', errors='replace')
|
||||
to(log_file + ':\n\n' + log)
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user