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

Does it works with Ruby 1.9 and V8 on Linux box ? #33

Open
falaise opened this issue May 9, 2011 · 1 comment
Open

Does it works with Ruby 1.9 and V8 on Linux box ? #33

falaise opened this issue May 9, 2011 · 1 comment

Comments

@falaise
Copy link

falaise commented May 9, 2011

Hello,

I try to write a little script with Ruby on a Linux Fedora 64 bits box.
I am using the gem 'therubyracer-heroku-0.8.1' for the V8 machine because the gem 'therubyracer' fails to compile on 64 bits with gcc RedHat 4.5.1.

So, in my script, i load the 'envjs/rubyracer.rb' and it success with Ruby 1.8.7 but fails with Ruby 1.9.2 for two reasons :

-1) 'configure_context' method fails for compatibility reason on 'eval'. Just add to_s method to the parameter of 'eval'.
-2) Exception raised with that stack :

👎 Uncaught TypeError: Cannot convert object to primitive value

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:118:in block in v8': undefined methodSetHiddenValue' for # (NoMethodError)
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:117:in tap'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:117:inv8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:111:in block (2 levels) in v8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:110:ineach'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:110:in block in v8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:109:intap'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:109:in v8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:19:inblock (2 levels) in []='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:75:in block in open'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/context.rb:79:inenter'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:74:in open'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:18:inblock in []='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:17:in tap'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:17:in[]='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/context.rb:58:in []='
envjs/rubyracer.rb:47:inconfigure_context'
from ./go.sh:7:in load'
from ./go.sh:7:in'

Any idea ?

Regards.

@thatcher
Copy link
Owner

I'm not a very skilled ruby developer so I'm going to have to punt and ask
around. Fortunately the ruby platform bridge code is very small so I should
be able to determine if it's an issue particular to envjs or therubyracer.
My current free cycles are pretty slim so if you find out first let me
know! Thanks for the post.

Thatcher

On Mon, May 9, 2011 at 5:34 AM, falaise <
reply@reply.github.com>wrote:

Hello,

I try to write a little script with Ruby on a Linux Fedora 64 bits box.
I am using the gem 'therubyracer-heroku-0.8.1' for the V8 machine because
the gem 'therubyracer' fails to compile on 64 bits with gcc RedHat 4.5.1.

So, in my script, i load the 'envjs/rubyracer.rb' and it success with Ruby
1.8.7 but fails with Ruby 1.9.2 for two reasons :

-1) 'configure_context' method fails for compatibility reason on 'eval'.
Just add to_s method to the parameter of 'eval'.
-2) Exception raised with that stack :

👎 Uncaught TypeError: Cannot convert object to primitive value

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:118:in
block in v8': undefined methodSetHiddenValue' for # (NoMethodError)
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:117:in
tap'

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:117:inv8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:111:in
block (2 levels) in v8'

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:110:ineach'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:110:in
block in v8'

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:109:intap'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:109:in
v8'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:19:inblock
(2 levels) in []='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:75:in
block in open'

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/context.rb:79:inenter'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/portal.rb:74:in
open'
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:18:inblock
in []='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:17:in
tap'

ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/object.rb:17:in[]='
ruby-192p136/lib/ruby/gems/1.9.1/gems/therubyracer-heroku-0.8.1.pre3/lib/v8/context.rb:58:in
[]='
envjs/rubyracer.rb:47:inconfigure_context'
from ./go.sh:7:in load'
from ./go.sh:7:in'

Any idea ?

Regards.

Reply to this email directly or view it on GitHub:
#33

Christopher Thatcher

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

2 participants