byebug icon indicating copy to clipboard operation
byebug copied to clipboard

Segmentation Fault in Ruby 3.0 Rspec

Open noctivityinc opened this issue 3 years ago • 5 comments

Problem description

Replace this text with a description of the problem you're having. Make sure that you're running the latest stable release of both byebug and ruby and that the problem you're reporting hasn't been reported (and potentially fixed) already.

Expected behavior

byebug would work properly and not crash

Actual behavior

Segmentation fault:

-- Control frame information ----------------------------------------------- c:0069 p:0014 s:0364 E:000120 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/byebug-11.1.3/lib/byebug/attacher.rb:14 c:0068 p:0036 s:0360 E:002570 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/byebug-11.1.3/lib/byebug/attacher.rb:38 c:0067 p:0200 s:0356 E:001c90 BLOCK /Users/jlippiner/Projects/fruitstand/fhm/spec/models/subscription_spec.rb:258 [FINISH] c:0066 p:---- s:0347 e:000346 CFUNC :instance_exec c:0065 p:0015 s:0342 E:000b30 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:262 c:0064 p:0003 s:0337 E:000920 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:508 c:0063 p:0003 s:0334 E:0007a0 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:465 c:0062 p:0003 s:0331 E:001250 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/hooks.rb:486 c:0061 p:0003 s:0328 E:000080 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/hooks.rb:626 c:0060 p:0018 s:0325 E:001c90 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:350 c:0059 p:0009 s:0319 E:0008a8 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-rails-5.0.1/lib/rspec/rails/adapters.rb:75 [FINISH] c:0058 p:---- s:0315 e:000314 CFUNC :instance_exec c:0057 p:0013 s:0310 E:000ff0 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:455 c:0056 p:0010 s:0304 E:0021e0 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/hooks.rb:390 c:0055 p:0010 s:0298 E:001b00 BLOCK /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/hooks.rb:628 c:0054 p:0018 s:0295 E:000d30 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/rspec-core-3.10.1/lib/rspec/core/example.rb:350 c:0053 p:0005 s:0289 E:000a50 BLOCK /Users/jlippiner/Projects/fruitstand/fhm/spec/spec_helper.rb:58 c:0052 p:0006 s:0286 E:001378 METHOD /Users/jlippiner/.rvm/gems/ruby-3.0.0@fhm/gems/database_cleaner-core-2.0.1/lib/database_cleaner/strategy.rb:30 c:0051 p:0028 s:0281 E:000778 METHOD /Users/jlippiner/.rvm/rubies/ruby-3.0.0/lib/ruby/3.0.0/forwardable.rb:238

Steps to reproduce the problem

  1. Create a spec using latest version of Rspec
  2. Add byebug in the spec
  3. Crash

noctivityinc avatar Mar 30 '21 23:03 noctivityinc

I'm also getting this - anywhere I use byebug within Rspec - running Ruby 3.0.0 on Apple Silicon (M1).

simonrentzke avatar Apr 06 '21 04:04 simonrentzke

I have the same issue running Docker - Ubuntu 18.04 with Ruby 3.0.0 running version 11.1.3

Thellior avatar Apr 06 '21 10:04 Thellior

Updating to Ruby 3.0.1 fixed the issue.

simonrentzke avatar Apr 06 '21 23:04 simonrentzke

Can confirm that a upgrade to Ruby 3.0.1 fixed the issue. Thanks for the suggestion @simonrentzke

Thellior avatar Apr 07 '21 09:04 Thellior

That did seem to help for me.

On Wed, Apr 7, 2021 at 5:05 AM Erwin Kraan @.***> wrote:

Can confirm that a upgrade to Ruby 3.0.1 fixed the issue. Thanks for the suggestion @simonrentzke https://github.com/simonrentzke

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/deivid-rodriguez/byebug/issues/800#issuecomment-814742107, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAATIAXUZXKM3EWV3UKOF6DTHQN5FANCNFSM42DFDURA .

noctivityinc avatar Apr 07 '21 18:04 noctivityinc