From 7708bd311a328143884f5380a6d0effa3d070879 Mon Sep 17 00:00:00 2001 From: Jason Hollinger Date: Tue, 30 Apr 2024 20:12:32 -0400 Subject: [PATCH] Adjust script/extract_log to handle non-utf8 sequences. --- script/extract_log | 1 + 1 file changed, 1 insertion(+) diff --git a/script/extract_log b/script/extract_log index 7a9c294dd0..2898b6dd2f 100755 --- a/script/extract_log +++ b/script/extract_log @@ -46,6 +46,7 @@ end file = "#{app_root}/log/production.log" File.open(file).readlines.each do |line| + line.scrub! # remove non-utf8 characters match = line.match(/#(\d+)/) pid = match[1] if match if line.match?(/: Started [A-Z]{3,}/)