Skip to content

Commit

Permalink
Merge pull request #196 from Shopify/3.2.0-postponed-jobs
Browse files Browse the repository at this point in the history
Use postponed jobs on Ruby 3.2.0
  • Loading branch information
tenderlove committed Feb 22, 2023
2 parents 58312fb + cfe2a6e commit 52d1df6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/stackprof.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@

if defined?(RubyVM::YJIT) && RubyVM::YJIT.enabled?
StackProf.use_postponed_job!
elsif RUBY_VERSION == "3.2.0"
# 3.2.0 crash is the signal is received at the wrong time.
# Fixed in https://github.com/ruby/ruby/pull/7116
# The fix is backported in 3.2.1: https://bugs.ruby-lang.org/issues/19336
StackProf.use_postponed_job!
end

module StackProf
Expand Down

0 comments on commit 52d1df6

Please sign in to comment.