Weird Rails | Rake | Gems Error

  • Thread starter James Edward Gray II
  • Start date
J

James Edward Gray II

I'm seeing the strangest error this morning. Does the following
stack trace mean anything to anyone?

Thanks.

James Edward Gray II

$ rake test_units
(in /Users/james/Documents/Contract Jobs/HighGroove/robrady)
/usr/local/bin/ruby -Ilib:test "/usr/local/lib/ruby/gems/1.8/gems/
rake-0.6.2/lib/rake/rake_test_loader.rb" "test/unit/account_test.rb"
"test/unit/company_test.rb" "test/unit/contact_test.rb" "test/unit/
file_note_test.rb" "test/unit/file_status_test.rb" "test/unit/
file_type_test.rb" "test/unit/grade_test.rb" "test/unit/lab_test.rb"
"test/unit/link_test.rb" "test/unit/localization_test.rb" "test/unit/
notification_test.rb" "test/unit/priority_test.rb" "test/unit/
role_test.rb" "test/unit/supplier_type_test.rb" "test/unit/
ticket_test.rb"
/usr/local/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:74:in
`load_specification': undefined method `parse' for Time:Class
(NoMethodError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:307:in `date='
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:296:in `date='
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:384:in `send'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:384:in `initialize'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:383:in `each'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:383:in `initialize'
from (eval):1:in `new'
from (eval):1:in `load_specification'
... 24 levels...
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5:in `load'
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5:in `each'
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5
rake aborted!
Command failed with status (1): [/usr/local/bin/ruby -Ilib:test "/usr/
local...]
 
J

James Edward Gray II

I'm seeing the strangest error this morning.

Boy, I sure broke something. More weirdness:

$ rake migrate
(in /Users/james/Documents/Contract Jobs/HighGroove/robrady)
rake aborted!
WARNING: You have a nil object when you probably didn't expect it!
Odds are you
want an instance of Array instead.

Look in the callstack to see where you're working with an object that
could be nil.
Investigate your methods and make sure the object is what you expect!
/rakefile:201

James Edward Gray II
 
J

Jamis Buck

I'm seeing the strangest error this morning. Does the following
stack trace mean anything to anyone?

It looks like you might need to 'require "time"' somewhere (config/
environment.rb is always a good choice), as the core Time class does
not include a "parse" method.

- Jamis
Thanks.

James Edward Gray II

$ rake test_units
(in /Users/james/Documents/Contract Jobs/HighGroove/robrady)
/usr/local/bin/ruby -Ilib:test "/usr/local/lib/ruby/gems/1.8/gems/
rake-0.6.2/lib/rake/rake_test_loader.rb" "test/unit/
account_test.rb" "test/unit/company_test.rb" "test/unit/
contact_test.rb" "test/unit/file_note_test.rb" "test/unit/
file_status_test.rb" "test/unit/file_type_test.rb" "test/unit/
grade_test.rb" "test/unit/lab_test.rb" "test/unit/link_test.rb"
"test/unit/localization_test.rb" "test/unit/notification_test.rb"
"test/unit/priority_test.rb" "test/unit/role_test.rb" "test/unit/
supplier_type_test.rb" "test/unit/ticket_test.rb"
/usr/local/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:74:in
`load_specification': undefined method `parse' for Time:Class
(NoMethodError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:307:in `date='
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:296:in `date='
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:384:in `send'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:384:in `initialize'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:383:in `each'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/
specification.rb:383:in `initialize'
from (eval):1:in `new'
from (eval):1:in `load_specification'
... 24 levels...
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5:in `load'
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5:in `each'
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.6.2/lib/rake/
rake_test_loader.rb:5
rake aborted!
Command failed with status (1): [/usr/local/bin/ruby -Ilib:test "/
usr/local...]
 
J

Jamis Buck

Boy, I sure broke something. More weirdness:

$ rake migrate
(in /Users/james/Documents/Contract Jobs/HighGroove/robrady)
rake aborted!
WARNING: You have a nil object when you probably didn't expect
it! Odds are you
want an instance of Array instead.

Look in the callstack to see where you're working with an object
that could be nil.
Investigate your methods and make sure the object is what you expect!
./rakefile:201

Can you run it with --trace enabled?

$ rake --trace migrate

That might give us a more helpful backtrace.

- Jamis
 
J

James Edward Gray II

Can you run it with --trace enabled?

$ rake --trace migrate

That might give us a more helpful backtrace.

Thanks for trying to help here, I believe I fixed this issue.

James Edward Gray II
 
J

James Edward Gray II

It looks like you might need to 'require "time"' somewhere (config/
environment.rb is always a good choice), as the core Time class
does not include a "parse" method.

After spending half a day hunting this down, I can tell you it's
related to the salted_login_generator on Unix systems. The files it
drops in test/mocks/test/ called time.rb is the source of the
problem, though I can't explain exactly WHY yet. Windows seems
unaffected but two different Unixes started throwing that missing
parse() error.

James Edward Gray II
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top