Neil Middleton wrote:
This is all I get:
Processing Base#index (for 127.0.0.1 at 2006-10-23 21:48:20) [GET]
Session ID: 94945ea69c35bc6c335d70acf4a59310
Parameters: {}
I have the same problem coincidently running Ubuntu (Edgy) but with
Postgresql.
Here's what I did. Install ruby via apt, install ruby gems and rails
via instructions on rails site. Next I wrote a small test site by
myself that worked fine but did not use the database or rails scaffolds
(enter name, stuffs name in session and allows you to log out clearing
session). I decided to go back to the PragProg book and started on
chapter 6, installing the postgres gem.
Created and checked the database exists, that the user/password is
correct, that the rails page at http://localhost:3000 works. The
version info from that page is
Ruby version 1.8.4 (i486-linux)
RubyGems version 0.9.0
Rails version 1.1.6
Active Record version 1.14.4
Action Pack version 1.12.5
Action Web Service version 1.1.6
Action Mailer version 1.2.5
Active Support version 1.3.1
Application root /projects/learning/rails/depot
Environment development
Database adapter postgresql
development:
adapter: postgresql
database: depot_development
username: depot_dev
password: *apassword*
host: localhost
"./script/generate scaffold Product Admin" produced
exists app/controllers/
exists app/helpers/
exists app/views/admin
exists test/functional/
dependency model
exists app/models/
exists test/unit/
exists test/fixtures/
identical app/models/product.rb
identical test/unit/product_test.rb
identical test/fixtures/products.yml
Removing the directory and following all steps produces same output.
This was in log/development.log
Processing Base#index (for 127.0.0.1 at 2006-11-22 19:46:16) [GET]
Session ID: 099574b2922c609fefef547a70f3b953
Parameters: {}
ActionController::RoutingError (Recognition failed for "/admin"):
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.5/lib/action_controller/routing.rb:522:in
`recognition_failed'
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.5/lib/action_controller/routing.rb:512:in
`recognize!'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/dispatcher.rb:38:in
`dispatch'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/webrick_server.rb:115:in
`handle_dispatch'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/webrick_server.rb:81:in
`service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/webrick_server.rb:67:in
`dispatch'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/commands/servers/webrick.rb:59
/usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in
`require'
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
`require'
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/commands/server.rb:30
/usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in
`require'
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
`require'
./script/server:3
Rendering
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.5/lib/action_controller/templates/rescues/layout.rhtml
(404 Page Not Found)
Any ideas? The prag prog book suggests more files should be generated
but are not. app/view/admin is completely empty.
Cheers,
Chris