Women in Technology

Hear us Roar

  Rolling with Ruby on Rails
Subject:   Article disparity
Date:   2005-01-25 18:27:27
From:   Swirlee
This is a great article, but I've discovered one small snafu. When I create the MyTest controller, it creates a my_text_controller.rb, just as the article says. However, when I add the "Hello World" method and browse to the URL in the article (localhost/MyTest/), I get an error (LoadError in MyTest#index). However, if I put an underscore in the URL, i.e. localhost/My_Test/, it works perfectly. I'm not sure if this is just an error in the article or if there's been a change in the Rails implementation, but it could bear correcting. FYI, I'm running Ruby 1.8.2 and Rails 0.9.5.
Full Threads Oldest First

Showing messages 1 through 8 of 8.

  • Curt Hibbs photo Article disparity
    2005-01-30 00:20:45  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

    Please ignore what I said above about reverting to 0.9.4 -- this caused more problems than it solved. See my reply to "Not working as advertised" on 2005-01-30 00:15:59 for corrected details.
  • Curt Hibbs photo Article disparity
    2005-01-26 07:03:12  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

    This could be a change in Rails as 0.9.5 was just released last night. I will check it out later today and then post here again.
    • Curt Hibbs photo Article disparity
      2005-01-26 10:25:47  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

      Ok, I've confirmed it... this problem was caused by the recently released 0.9.5 version of Rails. The workaround (for this tutorial) is to specifically install version 0.9.4 of rails as follows:

      • If you already installed 0.9.5, uninstall it with the command "gem uninstall rails".

      • Install Rails 0.9.4 with the command "gem install rails -v 0.9.4".

      • Article disparity
        2005-01-28 10:41:00  rakesh_goa [View]

        woah. why reinstall 0.9.4? having the url match the .rb sounds like a bug fix in 0.9.5
        • Curt Hibbs photo Article disparity
          2005-01-28 10:56:48  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

          Something changed between 0.9.4 and 0.9.5 that broke the URLs being used in this tutorial. I changed the article's text to specifically install 0.9.4, because I don't want future changes in Rails to invalidate this tutorial. For those who have already installed 0.9.5, the instructions above allow them to go back to 0.9.4.

          Once you are past the tutorial and working on your own you would, obviously, want to be using the most recent version.
          • Article disparity
            2005-02-26 00:47:35  coreman [View]

            the tutorial URLs work fine with rails 0.10.0...

      • Article disparity
        2005-01-26 12:39:12  rubynewbie [View]

        well, i'm running on redhat fedora, and followed the installation instructions, got the same problem with the MyTest controller.. uninstalled and installed 0.9.4 as instructed.. but get the same error.. no combination of MyTest, My_Test, mytest, my_test works.. do i need a special version of ruby and all the other components as well? i got the latest ones from the sourceforge site.

        seems pretty finiky if something like this varies from version to version, please help!

        • Curt Hibbs photo Article disparity
          2005-01-26 12:45:14  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

          This sounds like a completely different problem. I would suggest posting your problem and console log to the Rails mailing list, other Rails developers can take a closer look. (I'll look too, but I'm a Windows guy).