This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new 755bc0ff Fix up matching; show whole line
755bc0ff is described below

commit 755bc0ffcd6af5d73772fdeedd20300ec31be5f6
Author: Sebb <[email protected]>
AuthorDate: Mon Jan 8 23:15:05 2024 +0000

    Fix up matching; show whole line
---
 www/status/monitors/public_json.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/www/status/monitors/public_json.rb 
b/www/status/monitors/public_json.rb
index 1ff2303e..3d608245 100644
--- a/www/status/monitors/public_json.rb
+++ b/www/status/monitors/public_json.rb
@@ -66,8 +66,8 @@ def Monitor.public_json(previous_status)
 
       # Ruby warnings, e.g.
       # /usr/lib/ruby/2.7.0/net/protocol.rb:66: warning: previous definition 
of ProtocRetryError was here
-      if contents.gsub!(%r{^/(?:var|usr|/srv/gems)/lib/\S+: (warning:.*?)\n+}, 
'')
-        status[name].merge! level: 'warning', data: $1 unless $1.include? 
'/net/protocol.rb:' # can't fix this
+      if contents.gsub!(%r{^/((?:var|usr|/srv/gems)/lib/\S+): 
(warning:.*?)\n+}, '')
+        status[name].merge! level: 'warning', data: $2 unless $1.include? 
'/net/protocol.rb:' # can't fix this
       end
 
       # Check to see if the log has been updated recently

Reply via email to