Forum: Ruby on Rails Is there a problem with map.root

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
gberz3 (Guest)
on 2007-03-17 21:15
(Received via mailing list)
Hi All,

I've taken a look at the rails API, and per it, I should be able to
say:


map.root :controller => 'controller_name'


. . .however, 'mongrel_rails start' seems to fail giving me an error:

** Starting Mongrel listening at 0.0.0.0:3000
** Starting Rails with development environment...
/usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/
action_controller/routing.rb:965:in `build': Illegal route:
the :controller must be specified! (ArgumentError)
        from /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/
action_controller/routing.rb:1172:in `add_route'
        from /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/
action_controller/routing.rb:1178:in `add_named_route'
        from /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/
action_controller/routing.rb:997:in `root_without_deprecation'
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/
active_support/deprecation.rb:94:in `root'
        from /Users/michwill/RUBY_PROJECTS/michael/config/../config/
routes.rb:2
        from /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/
action_controller/routing.rb:1139:in `draw'
        from /Users/michwill/RUBY_PROJECTS/michael/config/../config/
routes.rb:1
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/
active_support/dependencies.rb:488:in `load'
         ... 21 levels...
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0.1/lib/
mongrel/command.rb:211:in `run'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0.1/bin/
mongrel_rails:243
        from /usr/local/bin/mongrel_rails:16:in `load'
        from /usr/local/bin/mongrel_rails:16


Any ideas?

Thanks,
Michael
This topic is locked and can not be replied to.