Skip to content

Commit

Permalink
remove trap debugging (its already built into the knapsack_pro gem)
Browse files Browse the repository at this point in the history
  • Loading branch information
ArturT committed Aug 21, 2024
1 parent d5d382a commit feaed7b
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -254,24 +254,3 @@
Kernel.srand config.seed
=end
end

# Debugging: RSpec hangs / freezes
# https://github.com/rspec/rspec-rails/issues/1353#issuecomment-93173691
puts "rspec pid: #{Process.pid}"

trap 'USR1' do
threads = Thread.list

puts
puts "=" * 80
puts "Received USR1 signal; printing all #{threads.count} thread backtraces."

threads.each do |thr|
description = thr == Thread.main ? "Main thread" : thr.inspect
puts
puts "#{description} backtrace: "
puts thr.backtrace.join("\n")
end

puts "=" * 80
end

0 comments on commit feaed7b

Please sign in to comment.