Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segment Fault in 2.0.1 - 2.1.0pre3 and ruby 2.6.2p47 #133

Open
joeheald85 opened this issue Jun 24, 2019 · 13 comments
Open

Segment Fault in 2.0.1 - 2.1.0pre3 and ruby 2.6.2p47 #133

joeheald85 opened this issue Jun 24, 2019 · 13 comments

Comments

@joeheald85
Copy link

joeheald85 commented Jun 24, 2019

This is only occurring in a staging/ubuntu environment. Locally, on a MacOS/development environment, this is working fine.

/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/engine.rb:42: [BUG] Segmentation fault at 0x0000000000000000
ruby 2.6.2p47 (2019-03-13 revision 67232) [x86_64-linux-gnu]

-- Control frame information -----------------------------------------------
c:0028 p:---- s:0147 e:000146 CFUNC  :compile_data_context
c:0027 p:0298 s:0142 e:000141 METHOD /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/engine.rb:42
c:0026 p:0139 s:0130 E:0009b8 METHOD /home/deploy/rails/sequoia/releases/20190624195338/lib/custom_css.rb:28
c:0025 p:0042 s:0123 E:001e68 EVAL   (irb):1 [FINISH]
c:0024 p:---- s:0119 e:000118 CFUNC  :eval
c:0023 p:0021 s:0111 e:000110 METHOD /usr/lib/ruby/2.6.0/irb/workspace.rb:85
c:0022 p:0056 s:0103 e:000101 METHOD /usr/lib/ruby/2.6.0/irb/context.rb:385
c:0021 p:0020 s:0094 e:000093 BLOCK  /usr/lib/ruby/2.6.0/irb.rb:493
c:0020 p:0025 s:0091 e:000090 METHOD /usr/lib/ruby/2.6.0/irb.rb:647
c:0019 p:0008 s:0085 e:000084 BLOCK  /usr/lib/ruby/2.6.0/irb.rb:490
c:0018 p:0100 s:0080 e:000079 BLOCK  /usr/lib/ruby/2.6.0/irb/ruby-lex.rb:246 [FINISH]
c:0017 p:---- s:0076 e:000075 CFUNC  :loop
c:0016 p:0006 s:0072 e:000071 BLOCK  /usr/lib/ruby/2.6.0/irb/ruby-lex.rb:232 [FINISH]
c:0015 p:---- s:0069 e:000068 CFUNC  :catch
c:0014 p:0012 s:0064 e:000063 METHOD /usr/lib/ruby/2.6.0/irb/ruby-lex.rb:231
c:0013 p:0034 s:0060 E:0026d8 METHOD /usr/lib/ruby/2.6.0/irb.rb:489
c:0012 p:0005 s:0055 e:000054 BLOCK  /usr/lib/ruby/2.6.0/irb.rb:428 [FINISH]
c:0011 p:---- s:0052 e:000051 CFUNC  :catch
c:0010 p:0064 s:0047 E:001ea8 METHOD /usr/lib/ruby/2.6.0/irb.rb:427
c:0009 p:0102 s:0042 e:000041 METHOD /usr/lib/ruby/2.6.0/irb.rb:383
c:0008 p:0205 s:0036 e:000035 METHOD /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/console.rb:110
c:0007 p:0011 s:0032 e:000031 METHOD /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/console.rb:9
c:0006 p:0087 s:0027 e:000026 METHOD /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:68
c:0005 p:0028 s:0022 e:000021 METHOD /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:39
c:0004 p:0111 s:0017 e:000016 TOP    /home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands.rb:17 [FINISH]
c:0003 p:---- s:0012 e:000011 CFUNC  :require
c:0002 p:0108 s:0007 E:0011a8 EVAL   script/rails:39 [FINISH]
c:0001 p:0000 s:0003 E:000aa0 (none) [FINISH]

-- Ruby level backtrace information ----------------------------------------
script/rails:39:in `<main>'
script/rails:39:in `require'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands.rb:17:in `<top (required)>'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:68:in `console'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/console.rb:9:in `start'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/railties-4.2.10/lib/rails/commands/console.rb:110:in `start'
/usr/lib/ruby/2.6.0/irb.rb:383:in `start'
/usr/lib/ruby/2.6.0/irb.rb:427:in `run'
/usr/lib/ruby/2.6.0/irb.rb:427:in `catch'
/usr/lib/ruby/2.6.0/irb.rb:428:in `block in run'
/usr/lib/ruby/2.6.0/irb.rb:489:in `eval_input'
/usr/lib/ruby/2.6.0/irb/ruby-lex.rb:231:in `each_top_level_statement'
/usr/lib/ruby/2.6.0/irb/ruby-lex.rb:231:in `catch'
/usr/lib/ruby/2.6.0/irb/ruby-lex.rb:232:in `block in each_top_level_statement'
/usr/lib/ruby/2.6.0/irb/ruby-lex.rb:232:in `loop'
/usr/lib/ruby/2.6.0/irb/ruby-lex.rb:246:in `block (2 levels) in each_top_level_statement'
/usr/lib/ruby/2.6.0/irb.rb:490:in `block in eval_input'
/usr/lib/ruby/2.6.0/irb.rb:647:in `signal_status'
/usr/lib/ruby/2.6.0/irb.rb:493:in `block (2 levels) in eval_input'
/usr/lib/ruby/2.6.0/irb/context.rb:385:in `evaluate'
/usr/lib/ruby/2.6.0/irb/workspace.rb:85:in `evaluate'
/usr/lib/ruby/2.6.0/irb/workspace.rb:85:in `eval'
(irb):1:in `irb_binding'
/home/deploy/rails/sequoia/releases/20190624195338/lib/custom_css.rb:28:in `render'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/engine.rb:42:in `render'
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/engine.rb:42:in `compile_data_context'


-- C level backtrace information -------------------------------------------
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431573db5) [0x7fe431573db5]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431573fec) [0x7fe431573fec]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43141a0e7) [0x7fe43141a0e7]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4314fd072) [0x7fe4314fd072]
/lib/x86_64-linux-gnu/libc.so.6(0x7fe430fef4b0) [0x7fe430fef4b0]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(sass_value_get_tag+0x0) [0x7fe41ed56630]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass4EvalclEPNS_13Function_CallE+0x2032) [0x7fe41ee07482]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_11DeclarationE+0xf3) [0x7fe41ed98963]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_5BlockE+0x14b) [0x7fe41ed9841b]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_7RulesetE+0x69e) [0x7fe41ed9acbe]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_5BlockE+0x14b) [0x7fe41ed9841b]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_7RulesetE+0x69e) [0x7fe41ed9acbe]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_11Import_StubE+0x4e4) [0x7fe41ed97fe4]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_11Import_StubE+0x4e4) [0x7fe41ed97fe4]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_11Import_StubE+0x4e4) [0x7fe41ed97fe4]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(0x7fe41ee68b72) [0x7fe41ee68b72]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass6ExpandclEPNS_5BlockE+0x14b) [0x7fe41ed9841b]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass7Context7compileEv+0x2f4) [0x7fe41ee26ea4]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(_ZN4Sass12Data_Context5parseEv+0x277) [0x7fe41ee282f7]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(sass_compiler_parse+0x10e) [0x7fe41edb1e7e]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so(sass_compile_data_context+0x9f) [0x7fe41edb268f]
/usr/lib/x86_64-linux-gnu/libffi.so.6(ffi_call_unix64+0x4c) [0x7fe423c03e40]
/usr/lib/x86_64-linux-gnu/libffi.so.6(ffi_call+0x2eb) [0x7fe423c038ab]
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/ffi-1.11.1/lib/ffi_c.so(rbffi_CallFunction+0xe2) [0x7fe41f1bc662] Call.c:416
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/ffi-1.11.1/lib/ffi_c.so(rbffi_CallFunction) (null):0
/home/deploy/rails/sequoia/shared/bundle/ruby/2.6.0/gems/ffi-1.11.1/lib/ffi_c.so(custom_trampoline+0x30) [0x7fe41f1bfd70] MethodHandle.c:232
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155fa0a) [0x7fe43155fa0a]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431567eda) [0x7fe431567eda]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155fa0a) [0x7fe43155fa0a]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431568399) [0x7fe431568399]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_rescue2+0xe6) [0x7fe431420996]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431560f34) [0x7fe431560f34]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43156c6e9) [0x7fe43156c6e9]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155c396) [0x7fe43155c396]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_catch_obj+0x2c) [0x7fe43155c4ec]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431560f34) [0x7fe431560f34]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43156c6e9) [0x7fe43156c6e9]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155c396) [0x7fe43155c396]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_catch_obj+0x2c) [0x7fe43155c4ec]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431560f34) [0x7fe431560f34]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43145f5ba) [0x7fe43145f5ba]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe431461180) [0x7fe431461180]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_require_safe+0x9) [0x7fe431461279]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155b3cb) [0x7fe43155b3cb]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe4315672e3) [0x7fe4315672e3]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43155fa0a) [0x7fe43155fa0a]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(rb_vm_exec+0xb4) [0x7fe431565a64]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(0x7fe43141e2ea) [0x7fe43141e2ea]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(ruby_exec_node+0x1d) [0x7fe43142010d]
/usr/lib/x86_64-linux-gnu/libruby-2.6.so.2.6(ruby_run_node+0x2e) [0x7fe43142292e]
/usr/bin/ruby2.6(0x4008eb) [0x4008eb]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0) [0x7fe430fda830]
/usr/bin/ruby2.6(_start+0x29) [0x400939]
@joeheald85
Copy link
Author

joeheald85 commented Jun 25, 2019

Seems to be related to sass/sassc-rails#58 (comment)

Happens when it hits any asset pipeline helper, like image-url()

@joeheald85
Copy link
Author

Also note, this is using rails 4.2

sassc (2.1.0.pre3)
  ffi (~> 1.9)
sassc-rails (2.1.2)
  railties (>= 4.0.0)
  sassc (>= 2.0)
  sprockets (> 3.0)
  sprockets-rails
  tilt

sprockets (3.7.2)
  concurrent-ruby (~> 1.0)
  rack (> 1, < 3)
sprockets-rails (3.2.1)
  actionpack (>= 4.0)
  activesupport (>= 4.0)
  sprockets (>= 3.0.0)

@joeheald85 joeheald85 changed the title Segment Fault in 2.0.1 - 2.1.0pre3 and ruby 2.2.6p47 Segment Fault in 2.0.1 - 2.1.0pre3 and ruby 2.6.2p47 Jun 25, 2019
@ahorek
Copy link

ahorek commented Jul 29, 2019

@glebm this might be helpful

==13258== Invalid read of size 4
==13258==    at 0x17FF1630: sass_value_get_tag (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x180A2481: Sass::Eval::operator()(Sass::Function_Call*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x1804F57D: Sass::Eval::operator()(Sass::List*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x18033962: Sass::Expand::operator()(Sass::Declaration*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x18103B71: ??? (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x1803341A: Sass::Expand::operator()(Sass::Block*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x18035CBD: Sass::Expand::operator()(Sass::Ruleset*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x18103B71: ??? (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x1803341A: Sass::Expand::operator()(Sass::Block*) (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x180C1EA3: Sass::Context::compile() (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x180C32F6: Sass::Data_Context::parse() (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==    by 0x1804CE7D: sass_compiler_parse (in /usr/local/rvm/gems/ruby-2.6.3-railsexpress/gems/sassc-2.1.0.pre3-x86_64-linux/lib/sassc/libsass.so)
==13258==  Address 0x0 is not stack'd, malloc'd or (recently) free'd

full report https://gist.github.com/ahorek/88a5bfc31a42d3be1f36783ae18ac3f4

@lucaong
Copy link

lucaong commented Sep 17, 2019

Hitting the same issue, only happening in development mode in a Ubuntu docker container with ruby 2.6.4p104 (2019-08-28 revision 67798) [x86_64-linux] and Rails 6.0

@lucaong
Copy link

lucaong commented Sep 17, 2019

Here is the beginning of my stack trace:

/usr/local/bundle/gems/sassc-2.2.0/lib/sassc/engine.rb:42: [BUG] Segmentation fault at 0x0000000000000000
ruby 2.6.4p104 (2019-08-28 revision 67798) [x86_64-linux]

-- Control frame information -----------------------------------------------
c:0156 p:---- s:1061 e:001060 CFUNC  :compile_data_context
c:0155 p:0298 s:1056 E:0006c0 METHOD /usr/local/bundle/gems/sassc-2.2.0/lib/sassc/engine.rb:42
c:0154 p:0006 s:1044 E:0013b0 BLOCK  /usr/local/bundle/gems/sassc-rails-2.1.2/lib/sassc/rails/template.rb:40
c:0153 p:0056 s:1041 E:001428 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/utils.rb:171
c:0152 p:0164 s:1034 E:001388 METHOD /usr/local/bundle/gems/sassc-rails-2.1.2/lib/sassc/rails/template.rb:39
c:0151 p:0009 s:1025 E:001458 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/sass_processor.rb:30
c:0150 p:0053 s:1020 E:0014a0 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:75
c:0149 p:0016 s:1012 E:001530 BLOCK  /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:57 [FINISH]
c:0148 p:---- s:1007 e:001006 CFUNC  :reverse_each
c:0147 p:0039 s:1003 E:0014f0 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:56
c:0146 p:0393 s:0995 E:000650 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/loader.rb:134
c:0145 p:0073 s:0975 E:0015c8 BLOCK  /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/loader.rb:60
c:0144 p:0038 s:0969 E:000990 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/loader.rb:317
c:0143 p:0155 s:0959 E:001588 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/loader.rb:44
c:0142 p:0012 s:0950 E:001630 BLOCK  /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/cached_environment.rb:20 [FINISH]
c:0141 p:0008 s:0942 E:001668 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/cached_environment.rb:47
c:0140 p:0008 s:0935 E:001698 BLOCK  /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/bundle.rb:23
c:0139 p:0083 s:0931 E:0016e8 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/utils.rb:200
c:0138 p:0098 s:0920 E:0025b8 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/bundle.rb:24
c:0137 p:0053 s:0905 E:001730 METHOD /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:75
c:0136 p:0016 s:0897 E:0017c0 BLOCK  /usr/local/bundle/gems/sprockets-3.7.2/lib/sprockets/processor_utils.rb:57 [FINISH]
c:0135 p:---- s:0892 e:000891 CFUNC  :reverse_each
...

@CHTJonas
Copy link

Am also being affected by this issue.

$ ruby -v
ruby 2.6.3p62 (2019-04-16 revision 67580) [x86_64-darwin18]

$ rails -v
Rails 6.0.0

$ bundle info sassc
  * sassc (2.2.1)
	Summary: Use libsass with Ruby!
	Homepage: https://github.com/sass/sassc-ruby
	Path: /Users/charlie/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/sassc-2.2.1

$ rails assets:clobber assets:precompile
I, [2019-10-12T22:51:58.478414 #77688]  INFO -- : Removed /Users/charlie/Development/roombooking/public/assets
Removed webpack output path directory /Users/charlie/Development/roombooking/public/packs
yarn install v1.19.1
[1/4] 🔍  Resolving packages...
success Already up-to-date.
✨  Done in 0.52s.
/Users/charlie/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/sassc-2.2.1/lib/sassc/engine.rb:42: [BUG] Segmentation fault at 0x0000000000000000
ruby 2.6.3p62 (2019-04-16 revision 67580) [x86_64-darwin18]

See attached below for my full stack traces and crash reports:

@glebm
Copy link
Contributor

glebm commented Oct 19, 2019

See rails/sprockets#581 (comment) for a workaround

tahb added a commit to UKGovernmentBEIS/beis-report-official-development-assistance that referenced this issue Nov 7, 2019
* During Heroku deploys we can build a new container successfully, but the release phase fails with a seg fault with similar output to sass/sassc-ruby#133
* After a lot of cross referencing between this app and a recent working example of Heroku containers (https://github.com/LBHackney-IT/report-a-defect) it worked until Standard.rb was added and bumped this gem. Setting it backwards until a new version can be made fixed the issue.
* Tests run, including standard. And the page is styled correctly with it's assets precompiled. There doesn't _look_ to be a negative impact of removing reverting minor update.
Floppy added a commit to openpolitics/groupthink that referenced this issue Jan 14, 2020
@DavidS
Copy link

DavidS commented Mar 18, 2020

This (or something closely adjacent) is still happening with sassc 2.2.1 and ruby 2.7.0: https://github.com/puppetlabs/iac/runs/516329222

/github/workspace/vendor/gems/ruby/2.7.0/gems/sassc-2.2.1/lib/sassc/engine.rb:42: [BUG] Illegal instruction at 0x00007fe9190061f1
ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [x86_64-linux]

-- Control frame information -----------------------------------------------
c:0047 p:---- s:0269 e:000268 CFUNC  :compile_data_context
c:0046 p:0293 s:0264 e:000263 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/sassc-2.2.1/lib/sassc/engine.rb:42
c:0045 p:0032 s:0252 e:000251 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-sass-converter-2.0.1/lib/jekyll/converters/scss.rb:182
c:0044 p:0007 s:0242 e:000241 BLOCK  /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/renderer.rb:102 [FINISH]
c:0043 p:---- s:0236 e:000235 IFUNC 
c:0042 p:---- s:0233 e:000232 CFUNC  :each
c:0041 p:---- s:0230 e:000229 CFUNC  :reduce
c:0040 p:0008 s:0225 e:000224 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/renderer.rb:100
c:0039 p:0120 s:0220 e:000219 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/renderer.rb:84
c:0038 p:0072 s:0214 e:000213 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/renderer.rb:63
c:0037 p:0035 s:0210 e:000208 METHOD /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/site.rb:523
c:0036 p:0008 s:0203 e:000202 BLOCK  /github/workspace/vendor/gems/ruby/2.7.0/gems/jekyll-4.0.0/lib/jekyll/site.rb:516 [FINISH]
c:0035 p:---- s:0199 e:000198 CFUNC  :each

@thodg
Copy link

thodg commented Apr 7, 2020

Hitting the same backtrace on OpenBSD, sassc-2.2.1

@rompic
Copy link

rompic commented Apr 19, 2020

I still hit this or something similar when trying to hunt a memory leak with mwrap
sassc-ruby 2.3.0 and rails/sprockets#630 do not fix it for me, neither does setting export_concurrent to false.

@mechiland
Copy link

Same issue here: sassc 2.3.0 + ruby 2.6.6 on Ubuntu 18.04.

@ordinz
Copy link

ordinz commented May 24, 2020

check out rails/sprockets#633

@bogn83
Copy link

bogn83 commented Nov 17, 2020

For us an update to sassc 2.4.0 which included an update of ffi from 1.11.1 to 1.13.1 fixed it.

sassc 2.2.1 brought a LoadError fix and 2.3.0 made the arch native flag default to false.

@rompic & @mechiland should you still encounter this issue you may try installing like this: bundle config --local build.sassc --disable-march-tune-native which is taken from this #146 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests