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

Segmentation fault ruby 1.9.3p362 (2012-12-25 revision 38607) [i686-linux] #827

Closed
PlugIN73 opened this issue Dec 28, 2012 · 25 comments
Closed

Comments

@PlugIN73
Copy link

Link to build:
https://travis-ci.org/kaize/castle/builds/3853789
My project work in ruby 1.9.3-p327, how can i change it at travis?

@roidrage
Copy link
Contributor

Indeed odd, but wouldn't be the first time an MRI patch release broke something.

Here's another test suite that failed with a segfault: https://travis-ci.org/jordansissel/ruby-ftw/jobs/3863031/#L78

@bai
Copy link
Contributor

bai commented Dec 29, 2012

I keep getting 362 segfaulting hard as well.

@roidrage
Copy link
Contributor

Do you have a link to a build? This seems worth collecting evidence for and report as an MRI issue.

@bai
Copy link
Contributor

bai commented Dec 29, 2012

That's on staging env here, not on Travis. Just to let you know it's not likely to be Travis' problem.

@PlugIN73
Copy link
Author

I install 1.9.3p362 on my local machine and i have this problem. My question was - how can i change ruby build at travis?

@roidrage
Copy link
Contributor

Unfortunately this is the only 1.9.3 version we have available. You can try adding a previous one (e.g. 1.9.3p327) by adding a specific rvm version and seeing if that's available as a binary package from the rvm repository.

@PlugIN73
Copy link
Author

So, i have red bage on my develop branch...=(

@roidrage
Copy link
Contributor

Sorry about that. We're not very happy about patch level updates for an MRI version breaking things like that either.

Have you tried specifying something like 1.9.3-p327 as the rvm version?

@PlugIN73
Copy link
Author

Of course, i tryied at 327 and 194...
So, i will wait for next ruby release=)

@roidrage
Copy link
Contributor

@roidrage
Copy link
Contributor

@bai do you have any output from the segfaults in your staging environment? might be useful to have when reporting this as a bug.

@roidrage
Copy link
Contributor

There's already an open issue on the Ruby bug tracker: https://bugs.ruby-lang.org/issues/7629

@jimsynz
Copy link

jimsynz commented Dec 30, 2012

I'm getting segfaults on p362, but related to EM/thin, not AR. https://travis-ci.org/jamesotron/Heap/builds/3884041

@pixeltrix
Copy link

I've simplified this down to the following Active Record based code:

require 'active_record'

ActiveRecord::Base.establish_connection(:adapter => "sqlite3", :database => ":memory:")

ActiveRecord::Schema.define(:version => 1) do
  create_table :posts do |t|
    t.string :title
    t.timestamps
  end
end

class Post < ActiveRecord::Base
  default_scope { where(:published => true) }
  scope :page, Proc.new { |num| limit(10).offset(10 * (num - 1)) } do
    def current_page
      return 1 if limit_value.nil?
      (offset_value / limit_value) + 1
    end
  end
end

30.times do |i|
  Post.create! do |p|
    p.title = "Post #{i}"
  end
end

# Segfaults
Post.page(1)

The Active Record scope related code is somewhat complicated with respect to blocks and procs and I think we're relying on an implicit conversion of a block to a proc that has been removed with this change:

* vm.c (rb_vm_make_proc): No need to make Proc object here.

Now attempting to reproduce the segfault with straight ruby.

@lsegal
Copy link

lsegal commented Jan 3, 2013

Given the out of box problems with this release, would it be possible to roll back Ruby 1.9.3 to the previous patch level release until the problem is addressed? This is definitely a real (and sweeping) bug.

@roidrage
Copy link
Contributor

roidrage commented Jan 3, 2013

/cc @joshk

@joshk
Copy link
Contributor

joshk commented Jan 3, 2013

I will build new images and provision them across Org VMs ASAP.

On 3/01/2013, at 10:53 PM, Mathias Meyer notifications@github.com wrote:

/cc @joshk


Reply to this email directly or view it on GitHub.

@lsegal
Copy link

lsegal commented Jan 4, 2013

Any update on this, @joshk?

@joshk
Copy link
Contributor

joshk commented Jan 4, 2013

Working on it today sorry :(

Sent from my Commodore 64

On 5/01/2013, at 12:12 PM, Loren Segal notifications@github.com wrote:

Any update on this, @joshk?


Reply to this email directly or view it on GitHub.

@joshk
Copy link
Contributor

joshk commented Jan 5, 2013

New VMs have been created, I will put them live tomorrow, sorry for the delays. :)

On 5/01/2013, at 12:12 PM, Loren Segal notifications@github.com wrote:

Any update on this, @joshk?


Reply to this email directly or view it on GitHub.

@roidrage roidrage closed this as completed Jan 6, 2013
@jimsynz
Copy link

jimsynz commented Jan 8, 2013

Thanks for the hard work @joshk. It is appreciated.

@joshk
Copy link
Contributor

joshk commented Jan 8, 2013

My pleasure James :)

On 9/01/2013, at 11:47 AM, James Harton notifications@github.com wrote:

Thanks for the hard work @joshk. It is appreciated.


Reply to this email directly or view it on GitHub.

@lsegal
Copy link

lsegal commented Jan 8, 2013

Ditto @joshk! 👍!

@joshk
Copy link
Contributor

joshk commented Jan 8, 2013

Thanks Loren, it's my pleasure :)

On 9/01/2013, at 11:52 AM, Loren Segal notifications@github.com wrote:

Ditto @joshk! !


Reply to this email directly or view it on GitHub.

@PlugIN73
Copy link
Author

Thanks!!! Good work!

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

7 participants