-
-
Notifications
You must be signed in to change notification settings - Fork 898
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
Segmentation fault when using libxml-ruby & nokogiri in the same project. #1364
Comments
@Coren Thanks for asking this question. Nokogiri tries extremely hard to work well with We try to work around this, but GC is complex, in particular regarding the order in which objects may be freed (which may not agree with the order that libxml2 would like (which is 90% of the difficulty of wrapping Ruby around libxml2)). An example of this is viewable here: You'll note that the stack walkback indicates this is happening at document free-time. Unfortunately, the mixed-use case of libxml-ruby and nokogiri is simply something we can't guarantee is going to work, and is therefore not really supported. I'd love to know why both libraries are being used at the same time. What dependency is using libxml-ruby (and is it HappyMapper)? I'm going to close this, but feel free to follow up with more information that might be actionable. And thanks for using Nokogiri. |
Ah, I missed that you said you were using ruby-oai. I'm not familiar with it, unfortunately. |
Forgot to be explicit: if you can provide a reproducible test case, I'm happy to look into what we can do to work better with libxml-ruby. It's just that this comes up once a year or so, and I generally don't get lucky enough to get such a repro script. :( |
Ok. I'll see if I can do something about a repro script. |
I'm going to cut v1.6.8.rc3 tonight, which addresses another edge case with libxml-ruby, and so it may be worth trying that version out to see if it addresses your case. I've also added the start of some tests around libxml-ruby conflicts, and so any test case you can provide would be easy to merge into our test suite. |
Hi,
I'm having this kind of crash for a job in a ruby on rails project.
I have never seen it when I launch it from a "normal" ruby process (irb or webrick)
It always happens when I launch it from Sidekiq.
I have upgraded to latest versions with rvm, and I have seen same behaviour.
Basically, what my source code is doing:
Here is the trace
The text was updated successfully, but these errors were encountered: