Hi, I just got bitten by the issue explained on this link: http://github.com/rails/rails/commit/4817bf94d135c44ddfae1a30acb15de989e3c86c#comment_52435 Has anyone else seen this? Is it possible it's a jruby issue and not a rails issue? It's not clear to me since I'm still trying to get a MRI 1.8.7 setup check with. Thanks
on 2010-03-03 23:52
on 2010-03-04 02:15
On Wed, Mar 3, 2010 at 4:52 PM, Patrik Sundberg <patrik.sundberg@gmail.com> wrote: > Hi, > I just got bitten by the issue explained on this > link:Â http://github.com/rails/rails/commit/4817bf94d135c44ddfae1a30acb15de989e3c86c#comment_52435 > Has anyone else seen this? Is it possible it's a jruby issue and not a rails > issue? It's not clear to me since I'm still trying to get a MRI 1.8.7 setup > check with. Interesting...it does look like something that could be a JRuby bug, since I assume it works for them on MRI. Are you able to reduce it to something simple where JRuby differs from other impls? - Charlie --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
on 2010-03-04 11:05
Actually, seems to affect MRI 1.8.7 as well (jruby in 1.8 mode gives the
same. Examples below - I'm using a specific ref to avoid some unrelated
issues.
psundberg@lnpsprod1:~/dev/191test $ ruby -v
ruby 1.8.7 (2010-01-10 patchlevel 249) [x86_64-linux]
psundberg@lnpsprod1:~/dev/191test $ cat Gemfile
git 'git://github.com/rails/rails.git', 'ref' =>
'a4111bbca0884e4a748ab32ba7d7b550ec8d9186'
gem 'activesupport', '~> 3.0.0.beta1', :require => 'active_support'
psundberg@lnpsprod1:~/dev/191test $ bundle install --relock
Updating git://github.com/rails/rails.git
Resolving dependencies
Installing activesupport (3.0.0.beta1) from
git://github.com/rails/rails.git (at a4111bb)
Installing builder (2.1.2) from system gems
Installing i18n (0.3.5) from system gems
Installing memcache-client (1.7.8) from system gems
Installing tzinfo (0.3.16) from system gems
Your bundle is complete!
The bundle is now locked. Use `bundle show` to list the gems in the
environment.
psundberg@lnpsprod1:~/dev/191test $ irb
ruby-1.8.7-p249 > DateTime.new
NameError: uninitialized constant DateTime
from (irb):1
ruby-1.8.7-p249 > require '.bundle/environment'
=> true
ruby-1.8.7-p249 > Bundler.require :default
=> [:default]
ruby-1.8.7-p249 > require 'active_support/core_ext'
=> true
ruby-1.8.7-p249 > DateTime.new
=> Mon, 01 Jan -4712 00:00:00 +0000
ruby-1.8.7-p249 > DateTime.new.to_date.class
=> DateTime
On MRI 1.9.1:
psundberg@lnpsprod1:~/dev/191test $ ruby -v
ruby 1.9.1p420 (2010-02-04 revision 26571) [x86_64-linux]
psundberg@lnpsprod1:~/dev/191test $ bundle install --relock
Updating git://github.com/rails/rails.git
Resolving dependencies
Installing activesupport (3.0.0.beta1) from
git://github.com/rails/rails.git (at a4111bb)
Installing builder (2.1.2) from system gems
Installing i18n (0.3.5) from system gems
Installing memcache-client (1.7.8) from system gems
Installing tzinfo (0.3.16) from system gems
Your bundle is complete!
The bundle is now locked. Use `bundle show` to list the gems in the
environment.
psundberg@lnpsprod1:~/dev/191test $ irb
irb(main):001:0> DateTime.new
NameError: uninitialized constant DateTime
from (irb):1
from /dat/schurman/user-root/opt/ruby191/bin/irb:12:in `<main>'
irb(main):002:0> require '.bundle/environment'
=> true
irb(main):003:0> Bundler.require :default
=> [:default]
irb(main):004:0> require 'active_support/core_ext'
=> true
irb(main):005:0> DateTime.new
=> Mon, 01 Jan -4712 00:00:00 +0000
irb(main):006:0> Date.new.to_date.class
=> Date
I'll follow up with the rails guys - don't understand how this has
managed to not trip up others and it's an old commit..
Btw, jruby --1.9 mode works as as it should:
psundberg@lnpsprod1:~/dev/jruby15test $ ruby -v
jruby 1.5.0.dev (ruby 1.8.7 patchlevel 174) (2010-03-03 c37037a) (Java
HotSpot(TM) 64-Bit Server VM 1.6.0_17) [amd64-java]
psundberg@lnpsprod1:~/dev/jruby15test $ bundle install --relock
Updating git://github.com/rails/rails.git
Resolving dependencies
Installing activesupport (3.0.0.beta1) from
git://github.com/rails/rails.git (at a4111bb)
Installing builder (2.1.2) from system gems
Installing i18n (0.3.5) from system gems
Installing memcache-client (1.7.8) from system gems
Installing tzinfo (0.3.16) from system gems
Your bundle is complete!
The bundle is now locked. Use `bundle show` to list the gems in the
environment.
psundberg@lnpsprod1:~/dev/jruby15test $ ruby --1.9 -S irb
jruby-head > DateTime.nwe
NameError: uninitialized constant DateTime
from
/home/psundberg/.rvm/rubies/jruby-head/lib/ruby/1.9/irb/ruby-token.rb:99
:in `const_missing'
from (irb):2:in `irb_binding'
Maybe IRB bug!!
jruby-head > require '.bundle/environment'
=> true
jruby-head > Bundler.require :default
=> [:default]
jruby-head > require 'active_support/core_ext'
=> true
jruby-head > DateTime.new
=> Mon, 01 Jan -4712 00:00:00 +0000
jruby-head > DateTime.new.to_date.class
=> Date
on 2010-03-05 15:55
On Thu, Mar 4, 2010 at 4:05 AM, Sundberg, Patrik <Patrik.Sundberg@uk.mlp.com> wrote: > Actually, seems to affect MRI 1.8.7 as well (jruby in 1.8 mode gives the > same. Examples below - I'm using a specific ref to avoid some unrelated > issues. > irb(main):006:0> Date.new.to_date.class > > => Date Should this have been DateTime.new.to_date? This differs from your 1.8.7 example. > I'll follow up with the rails guys - don't understand how this has managed > to not trip up others and it's an old commit.. Ok...could still be an issue somewhere in JRuby, but it's definitely confusing how they wouldn't have seen it if it breaks 1.8.7 too. > Btw, jruby --1.9 mode works as as it should: ... > jruby-head > DateTime.new.to_date.class > > Â => Date Ok. - Charlie --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.