We try to keep our books accurate, but sometimes mistakes creep in. This page lists the errors submitted by our astute readers. If you've found a new error, please submit it.

The latest version of the book is P2.0, released 23 days ago. If you've bought a PDF of the book and would like to upgrade it to this version (for free), visit your home page.

Key: Typo Tech. Error Suggestion Not a problem Next edition

By default this page displays the errata for the latest version of the book. If you have a previous version, select it here:  

(To find out what version you have, look at the copyright page, a few pages in from the front of the book. If it says (say) 'Second Printing', then here it'll be P2.0. If there are interim PDF releases in that printing, they'll be 2.1, 2.2, and so on.)

PDF Paper Description Found in Fixed in
0
#51478: This issue happens only with Kindle format of the book. When code listing is too wide, right part of it is cropped. Example is at location 5...more...
B2.0
08-May-13
4
#52425: The section on installing on Windows suggests that the simplest way to set up the Rails stack is to use railsinstaller.org I have just talk...more...
B5.0
20-Aug-13
41
#76436: Where it says "Keys in a particular hash must be unique—you can’t have two entries for :drum.", should say "Keys in a particular hash are uniq...more...
P1.0
17-Feb-14
42
#53107: "In effect, though, you can ignore that it’s a hash and pretend that Ruby has keyword arguments." It sounds like this should have been upda...more...
P1.0
01-Nov-13
43
#52429: On page 41 in "Ruby Names" you mention that a name prefixed with a colon is a symbol (e.g. :symbol). On page 43 in "Arrays and Hashes" you m...more...
B5.0
20-Aug-13
47
#53134: The following sentence contains a query string within the URL, meaning a GET request is performed. However, the sentence indicates that a POST...more...
P1.0
10-Nov-13
47

#53191: Mention of impossibility of instantiating modules. But subsequent statement says "module's instance method".--Raj

P1.0
21-Nov-13
58
#76473: In introducing methods, you make use of a return statement that is in practice unwarranted since Ruby methods return their last-evaluated expr...more...
P1.0
04-Mar-14
76
#52962: In the /index.html.erb file, the list_description class needs to be added to the <table> tag not the <td> tag. As it stands, the css is not be...more...
B6.0
21-Sep-13
79
#76441: "Why test against 1 cent, rather than zero? Well, it’s possible to enter a number such as 0.001 into this field. Because the database stores j...more...
P1.0
21-Feb-14
79
#76480: I think that, regarding the numerical validation of the price, it must be stressed that errors could also be produced by storing legal but uni...more...
P1.0
05-Mar-14
82

#53041: The link to the MiniTest docs at the bottom of the page is broken.--Martín Raúl Villalba

P1.0
21-Oct-13
86

#52957: Link in footer to Mini Test in rdoc is broken, remove /unit and the link works.--Justin Hiltz

B6.0
20-Sep-13
91
#53363: To get the file products/index.html.erg to render properly in Firefox I had to add 'class="product"' (no single quotes) to the opening table t...more...
P1.0
18-Dec-13
98

#52407: Product description overwrites image unless I put it in <p></p> tags.

<p>
<%= sanitize(product.description) %>
</p>--Todd Crone

B5.0
18-Aug-13
98
#52444: sanitize(product.description) removes any html tags and hence it will never be nicely printed "to make the descriptions more interesting for o...more...
B5.0
23-Aug-13
100 86

#52940: "Document not found" for MiniTest1 framework URL--Chris Seelus

B6.0
16-Sep-13
104
#53259: Book say to change this flag to true to enable caching: config.action_controller.perform_caching = true But it doesn't work without this...more...
P1.0
01-Dec-13
108
#53002: There is no introduction or explanation as to the purpose of controllers/concerns. It appears without hardly any context. What is a concern us...more...
P1.0
01-Oct-13
108

#53092: The paragraph under current_card.rb states, that the code finally returns the new cart. As I see it, it doesn't, but returns the cart's id!--Stefan Otto

P1.0
30-Oct-13
112
#52625: The controller/concerns folder, introduced on page 112...I don't think there was any meaningful description about it prior two this page. It'...more...
B6.0
12-Sep-13
112
#52990: Please discuss the creation of a new file and the purpose of the controller/concerns folder. Nothing says outright that "we are going to creat...more...
B6.0
27-Sep-13
113

#76614: The correct way of accessing `product_id` from request's params is: params[:line_item][:product_id], not params[:product_id]

P2.0
04-Apr-14
116
#52463: Improve the implementation of "ensure_not_referenced_by_any_line_item" method. Since it does not follow the standard Ruby conventions. For exa...more...
B5.0
25-Aug-13
118
#52997: In the tenth-eleventh line from bottom, there is a space between "command" word and period sign: "... automatically by the scaffold command ....more...
B6.0
29-Sep-13
120
#76349: Hello People, Thanks for the fantastic reference. Maybe its just my lack of understanding here, but the following code (from the book) seem...more...
P1.0
30-Jan-14
124
#53076: Your code for show.html.erb at the bottom of the page doesn't fix the DRY issue. I believe it should be: <% if notice %> <p id="notice"><%= ...more...
P1.0
24-Oct-13
125

#52235: Footnote '2' link bellow page giving 404 not found error:

guides.rubyonrails.org/debugging_rails_applications.html%23the-logger--Frank Betorina

Susannah Davidson Pfalzer says: Frank, thank you for alerting us about this. We're trying to reproduce the problem - could you please let us know what PDF viewer you're using and what method you are using for accessing the page? (I.e., are you clicking on the link, or copying and pasting it in the browser?) - Susannah Pfalzer, editor
B4.0
25-Jul-13
125
#53028: I am reading a book P2.2 from 2012 and studying Rails4. I found a typo in the examples data from media.pragprog.com/titles/rails4/code/rails4-...more...
B1.0
16-Oct-13
127

#52236: Footnote '3' link bellow page giving 404 not found error:

github.com/rails/strong_parameters%23readme

B4.0
25-Jul-13
127
#76468: Even after applying the changes, notably to the destroy method in the carts controller, I'm still capable of browsing to which ever cart I lik...more...
P1.0
03-Mar-14
127
#76469: Even after applying the changes, notably to the destroy method in the carts controller, I'm still capable of browsing to which ever cart I lik...more...
P1.0
03-Mar-14
129
#54870: Between pages 129 and 130, essentially in the middle of a paragraph, while we are still talking about making a smarter cart, the sample codeba...more...
P1.0
20-Dec-13
140
#53200: (FYI the problems here could be due to changes in jQuery UI implementation) The inclusion of: form, div { display: inline; } insi...more...
P1.0
23-Nov-13
143
#53077: Adding this to application.js no longer works: //= require jquery-ui After about 15 minutes of fighting, I found this works: 1. gem insta...more...
P1.0
24-Oct-13
149
#76583: In the second paragraph, it says: "With that change in place, click any Add to Cart button, and you’ll see that the changed item in the cart g...more...
P1.0
30-Mar-14
149

#76584: In the cited code for the _cart partial, the line

<div class="cart_title">Your Cart</div>

should be

<h2>Your Cart</h2>

and that's all!--Antonio Vera

P1.0
30-Mar-14
150
#76585: The code to put in create.js.erb seems wrong in two aspects: first, the line we add should be added between the two existing lines, otherwise ...more...
P1.0
30-Mar-14
150
#76586: The animation done with Jquery's 'show' just doesn't work. The cart is shown, but the changes are not animated. I also had the same problem wi...more...
P1.0
30-Mar-14
153

#52988: 11.4 Iteration F4

code has not specific location--Chang Ju Park

B6.0
27-Sep-13
153
#59903: $(document).on "ready page:change", -> $('.store .entry > img').click -> $(this).parent().find(':submit').click() produces that produc...more...
P1.0
06-Jan-14
156

#53153: assert_select 'tr#current_item td', /Programming Ruby 1.9/
The dot in the RegEx should be escaped.--Patrick P. Henley

P1.0
15-Nov-13
166
#52562: In the paragraph beginning "Not surprisingly" you mention "our existing .js.erb template". It might better be phrase "our existing create.js.e...more...
B6.0
02-Sep-13
169
#53248: Pg 169 includes the 2nd of two adjustments to orders_controller_test.rb in chapter (12 "Check Out"). However, the chapter has no steps for run...more...
P1.0
30-Nov-13
191

#52385: Trivial, but you need to sanitize line_item.product.title in _line_item.text.erb. Buy "Programming Ruby 1.9 & 2.0" and you'll see why!--David Cunningham

B5.0
14-Aug-13
194
#76278: The changes made to the default '_form.html.erb' file (to improve the appearance of the user creation/modification form) created by the Rails ...more...
P1.0
10-Jan-14
198
#76704: In the paragraph after the form code, there's this phrase, which describes the parameters of the *_field_tag helpers: "The first is the name t...more...
P2.0
21-Apr-14
200

#53102: The route mapping delete 'logout' => :destroy does not work. --enddy dumbrique

P1.0
31-Oct-13
200

#76279: Should the route "delete 'logout' => :destroy" perhaps instead be "get 'logout' => :destroy" to permit logging out via a standard link in a browser?--Daniel Carter

P1.0
10-Jan-14
221

#58769: "Carrito bonita" -> "Carrito bonito"
because
carrito nombre masculino--Alexander Moiseyev

P1.0
27-Dec-13
381

#52977: In the first line in the list the 'object' and 'blob' seem to be out of place. Adding cell borders might be a good idea to improve readablity.

B6.0
23-Sep-13
2125
#52447: On kindle at location 2125, the link that points to "configuring a database" section of guides.rubyonrails.org is pointing to the wrong place....more...
B5.0
24-Aug-13