Generic-user-small David Lyon 4 posts

I ran through the part about adding user and compared everything, yet when I go to add a user, I get nothing. It dumps me at the index page with no flash, and no users.

I’ve been trying to figure out what is wrong with this for nearly an hour and I’m thinking maybe something was left out of this version of the book?

Edit: Here is the code I get in the console

Processing UsersController#index (for 127.0.0.1 at 2008-08-23 20:08:39) [POST] Session ID: 439c78b886bc8233093fb9d71e567ecb Parameters: {“user”=>{“name”=>”Dave”, “password_confirmation”=>””, “password”=>”“}, “commit”=>”Add User”, “authenticity_token”=>”8d18e9351f0e4ccf8bff4c7797d459dc36acfc31”, “action”=>”index”, “controller”=>”users”} User Load (0.000647) SELECT * FROM “users” ORDER BY name
Rendering template within layouts/users
Rendering users/index
Completed in 0.00887 (112 reqs/sec) | Rendering: 0.00146 (16%) | DB: 0.00158 (17%) | 200 OK [http://localhost/users]

 
Generic-user-small David Lyon 4 posts

Fixed: After restarting my server, everything worked fine.

 
Samr_small_small Sam Ruby 197 posts

What version of Rails are you running?

 
Generic-user-small David Lyon 4 posts

Rails 2.1.0 on OSX —it seems like it doesn’t like to generate routes on the fly as every time I’ve done anything with routes I’ve had to restart the server (this includes the changes like /3.xml etc…). It’s not a big issue, but I really think it might be something to note in the book somewhere.

I could also be totally wrong about the routes, I’ve been working in Rails for about a week now.

 
Samr_small_small Sam Ruby 197 posts

I’ve seen the behavior myself, and it has been reported a number of times. I’ve been looking for a reproducible test case, but so far have failed to produce one. There are people who are willing to fix the bug in Rails if they can track down the problem.

 
Generic-user-small David Lyon 4 posts

Interesting. My friend is also putting together Depot right now a little behind me, if he runs in to the same issue I’ll see if I can get you any more info. Thanks for taking the time to respond!

6 posts, 2 voices