ruby on rails - Routing Error: No route matches [GET] "/users/sign_up" -
i new stackoverflow , i'm learning ruby on rails. can't solve problem od localhost: no route matches [get] "/ users / sign_up" (devise gem).
here code:
routes.rb:
rails.application.routes.draw resources :posts resources :comments end root 'posts#index' '/about' => 'pages#about' end
in config/development.rb added:
config.action_mailer.default_url_options = { host: 'localhost', port: 3000 }
rake routes shows:
post_comments_path /posts/:post_id/comments(.:format) comments#index post /posts/:post_id/comments(.:format) comments#create new_post_comment_path /posts/:post_id/comments/new(.:format) comments#new edit_post_comment_path /posts/:post_id/comments/:id/edit(.:format) comments#edit post_comment_path /posts/:post_id/comments/:id(.:format) comments#show patch /posts/:post_id/comments/:id(.:format) comments#update put /posts/:post_id/comments/:id(.:format) comments#update delete /posts/:post_id/comments/:id(.:format) comments#destroy posts_path /posts(.:format) posts#index post /posts(.:format) posts#create new_post_path /posts/new(.:format) posts#new edit_post_path /posts/:id/edit(.:format) posts#edit post_path /posts/:id(.:format) posts#show patch /posts/:id(.:format) posts#update put /posts/:id(.:format) posts#update delete /posts/:id(.:format) posts#destroy root_path / posts#index about_path /about(.:format) pages#about
i restarted server nothing helps. haven't found hint in similar topics.
thanks
ok, found solution. in gemfile should be:
gem 'devise': git => 'https://github.com/plataformatec/devise.git'
(v. 4.0.0) instead
gem 'devise' '~> 3.3.0'
devise 3.3.0 not compatible rails 4.2.
thanks
Comments
Post a Comment