#688 open
Betelgeuse

Hobo model router blows up if routes are not added in routes.rb

Reported by Betelgeuse | April 7th, 2010 @ 10:59 AM | in Hobo 1.0X

I wanted to quickly add just front controller to a project where I was using just hobofields for models but not hobo otherwise. It seems the model router blows up if routes are not added in routes.rb. If not having the routes is not supported, it should at least detect it and fail gracefully but I doubt it's a lot of work to just make linkable? return false when the routes are not on.

** Invoke hobo:generate_taglibs (first_time)
** Invoke environment (first_time)
** Execute environment
** Execute hobo:generate_taglibs
rake aborted!
You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.member?
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/model_router.rb:56:in `linkable?'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:200:in `linkable?'
rapid/pages:6:in `run_one'
rapid/pages:6:in `select'
rapid/pages:6:in `run_one'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:88:in `run_for_subsite'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:87:in `each_pair'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:87:in `run_for_subsite'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:81:in `run'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:81:in `each'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:81:in `run'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/dryml/dryml_generator.rb:50:in `run'
/Library/Ruby/Gems/1.8/gems/hobo-1.0.0/lib/hobo/tasks/../../../tasks/hobo_tasks.rake:33
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `call'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `execute'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `each'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `execute'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in `invoke_with_call_chain'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in `invoke_with_call_chain'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:583:in `invoke'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2051:in `invoke_task'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `each'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2023:in `top_level'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2001:in `run'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/lib/rake.rb:1998:in `run'
/Library/Ruby/Gems/1.8/gems/rake-0.8.7/bin/rake:31
/usr/bin/rake:19:in `load'
/usr/bin/rake:19

Comments and changes to this ticket

  • Matt Jones

    Matt Jones September 14th, 2011 @ 10:09 PM

    • State changed from “new” to “open”
    • Milestone set to Hobo 1.0X
    • Milestone order changed from “0” to “0”

    Not sure if this is still an issue in 1.3.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Tags

Pages