From 4af37073a4f767596f9af4a0fd30779a97781fac Mon Sep 17 00:00:00 2001 From: Alexander Momchilov Date: Fri, 2 May 2025 17:48:46 -0400 Subject: [PATCH] Shush the `backtrace_locations`, too --- lib/spring/application.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/spring/application.rb b/lib/spring/application.rb index d713e82e..c460b77b 100644 --- a/lib/spring/application.rb +++ b/lib/spring/application.rb @@ -320,6 +320,7 @@ def shush_backtraces if $! lib = File.expand_path("..", __FILE__) $!.backtrace.reject! { |line| line.start_with?(lib) } unless $!.backtrace.frozen? + $!.backtrace_locations.reject! { |line| line.path&.start_with?(lib) } unless $!.backtrace_locations.frozen? end end end @@ -331,6 +332,7 @@ def shush_backtraces if $! lib = File.expand_path("..", __FILE__) $!.backtrace.reject! { |line| line.start_with?(lib) } unless $!.backtrace.frozen? + $!.backtrace_locations.reject! { |line| line.path&.start_with?(lib) } unless $!.backtrace_locations.frozen? end end end