What are the best Rails 3 books that really reduce learning curve, gotchas and generally avoid all the out of date info online?

Rails seems like it's a great platform... just the documentation isn't as in-depth as I would like beyond the simplest cases.... and "google" is not necessary the best way to learn things because lots of forums and blogs show you how to do things using earlier versions. It's not always easy to separate what's relevant from what isn't relevant. All of this can make a person less productive rather than more productive.

So... are there any books that really help reduce the learning curve and gotchas with developing COMPLEX applications with Rails 3?

Some criteria:

1. I am not looking for a "how to" book. I am already 530 tests in and understand quite a bit about rails already in the 2 weeks that I've been using. I'm a programmer of 19 years and have been building web apps for a long time.

2. I am not looking for a book that spends 20%-50% of its pages explaining how to program in OO... or what an MVC architecture is... or what an ORM is. I can actually write these libraries/frameworks if I really had the time, so understanding is not the problem :wink:

3. I am really more interested in a book or set of books/resources that cover all the gotchas that you WILL come across when building COMPLEX applications - something that is up-to-date.

4. The real problem with examples and samples online is that they are just too simple. I always find myself I am really interested in books that don't cover the "simple" examples, but also the "exceptions" to the examples/scenarios that are likely most complex and highly customized you are likely to see in a large application.

5. I am really interested in books that don't cover "how to setup devise", but rather, that cover the most useful customizations you'd ever want to do in Devise (just as an example... we can replace "Devise" with 'gem XYZ' here)

Do these resources exist? Or is grueling through the learning curve pretty much the best way to go about it?

The only reason I ask this is because I've come to the conclusion that IF you have 2-ish months to build a large application, and IF you are REALLY good at another platform... I am not convinced that Rails will help in the short term giving many of its documentation problems, out- of-date examples and general "gotchas" and "problems" that seem to occur a lot more frequently than say in Java/Spring.

I do fully admit that once you learn all the gotchas in Rails and the various plugins, and you know how to do "one of every complex thing" possible, you will be MUCH faster than in Java/Spring regardless of how good you are in Java. But that probably means you need to get 1-2 months of time under your belt using Ruby and Rails minimum.

Anyway, I've probably rambled enough. If you have any good books/ resources to help speed up my learning curve and take out a lot of guesswork and "solving weird problems in dark" type of issues, that would be awesome.

If you'd like to have discussion about other things, I'm always fair game with that. LOL.

Oh, one more thing:

One of the biggest things I find myself googling is testing. Because so much magic happens, I am always googling to find out "how do I test this?!" I seem to come up with testing gotchas and problems all the time.

Googling about testing actually results in very poor results. For example, if you google testing validations, you will come across Ruby 2.0 testing code that is obsolete... or you'll find a way of testing that doesn't cover all the cases and is kind of bloated. You'd think one would not have to reinvent the wheel about "how to test validations", but that's actually what happened in my case (my solution I coded myself is rather quite nice... I wish I saw it online though :/)

Once you throw in Devise into the mix, testing gets even more complicated. For example, devise gives you the necessary methods when testing controllers, but will not include them for Helpers - even if you specify that it should. It's really very odd behaviour. This type of random "doesn't just work" situation seems to happen all the time for me.

Anyway, maybe now I am just venting. I am finding the whole "learning a new platform" to be perhaps a lot more work than I thought it would be.

I'm starting to think a "bloated Java programmer who's REALLY good at that bloat" can probably still produce faster than someone learning Rails. Of course, eventually, the Rails programmer will outpace him... but it might take awhile.

- Anything from PragProg.com - The Rails 3 way is priceless

Kind Regards, Chad Eubanks The Code Boutique

Rails 3 way is definitely the way to go. Its very much like the book you want.

Railstutorial.org is a great resource for learning testing with rspec. Pragprog.com has a great testing book.

Banks

- Anything from PragProg.com - The Rails 3 way is priceless

Kind Regards, Chad Eubanks The Code Boutique

Hi Chad :wink:

Yeah, the Rails 3 Way looked like an interesting book. It had mixed reviews when I did some searching, so I wasn't sure. I liked how it wasn't branded on being a book for beginners.

If I had to get *2* books from there, what would the other be?

Rails 3 way is the way to go. For testing search for Michael Hartl tutorial. Its has some great examples for test driven development. You should also try looking at some very good open source rails projects on github. They have lots of testing examples and very up-to- date.

Combining these resources will great. As no single book will be up to date. Rails develop really very fast.

yea the pragmatic programmers books on Rails are often considered the best.

Although not about rails, if you want a good book about Ruby I'd recommend O'Reilly's book _The Ruby Programming Language_ (Flanagan / Matsumoto). I found that even though I had a lot of experience with programming there are areas of Ruby where having a definitive book is really good (like splats, procs & lambda, etc)

-Jason

The Rails 3 Way is a must. From pragprog, I believe there is a testing specific book.

Banks

Railstutorial.org is a great resource for learning testing with rspec. Pragprog.com has a great testing book.

Banks

Yeah, I saw that website and it seemed like it was a little basic for where I am at. I managed to do everything hes teaching in just a week or so on my own, so I'm not sure how much I'd learn.

Do the PragProg books show both the tests and the working code?

I think Ryan Bate's screencasts are pretty good (I've watched lots already... maybe 50 of them at least). I found them to be pretty helpful. Sometimes they are out of date though.

One of the drawbacks to the Ryan Bate's screencasts though is that they doesn't show the test code along side with the actual production code. It's a shame because in the "real world", you are likely going to want to write both.

I guess there's a lot of "how to do something", but a very small % of "how to test the things we are trying to teach you." I finally googling the "how to test" part to be a really big time-sink. The "searching" takes more time than the actual testing :frowning:

If you really want to step your rails game up. I would highly recommend training from pragprog or big nerd ranch.

I did a week long training with big nerd ranch for rails and it was by far the best resource I've used to developed myself.

Kind Regards, Chad Eubanks The Code Boutique

You should also try looking at some very good open source rails projects on github. They have lots of testing examples and very up-to- date.

That sounds like a great idea! Do you know of any names of ones I should look at? I am not even sure what is out there.

Oh, how is the Rails Antipatterns book? Is it something a seasoned developer in Java would get a lot out of, or is it something a good web developer ought to know already?

Diaspora, spree, radiant cms are the one I’m currently following.