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 P7.0,
released over 2 years 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.
| PDF |
Paper |
Description |
Found in |
Fixed in |
| nFsnE |
hZfHc |
#49581: Yes, I thought of the Chor-police coectnnion too, but in the text I thought it was more of a play on the word corpulent. About references to Mahabharata being to blatant, well, I guess that's because people are more familiar with a greater number of incidents from the Mahabharata. About Feluda, I still can't believe that too many people apart from Bongs have *read* it. Still haven't come across too many who have. But if it really IS true that a lot of non-Bongs (Bongs simply LOVE to throw around this term) HAVE read Feluda, then I think it's quite an embarrassment because quite a lot of my Bong friends haven't read either the original or the English translations.--STGdEufRcNZtwKcz #49581: Yes, I thought of the Chor-police coectnnion too, but in the text I thought it was more of a play on the word corpulent. About references to M ...more...
|
P7.0
26-Jul-12
|
|
| 7-1 |
|
#43547: There isn't an option for the epub version. Any ways, on chapter 7 page 5 there are two links to figures "Flow of buyer pages" and "Flow of seller pages" that point to the other figure. Buyer links to seller and vise versa--Tim Foster #43547: There isn't an option for the epub version. Any ways, on chapter 7 page 5 there are two links to figures "Flow of buyer pages" and "Flow of s ...more...
|
P6.0
04-Jun-10
|
|
| 10 |
|
#47042: this book covers a lot less than version 3.
I seem to be unable to find out about a lot of things such as STI, polymorphic model's, view select helpers to mention just a few off the top of my head.
Version 3 of this book was way more comprehensive, it would be good to see that comprehensiveness continue on into the future.--James West #47042: this book covers a lot less than version 3.
I seem to be unable to find out about a lot of things such as STI, polymorphic model's, view sele ...more...
|
P7.0
11-May-11
|
|
| 75 |
|
#48511: git-repoconfig is deprecated in favor of git config:
git config --get-regexp user.*
--Elfira
|
P7.0
13-Jan-12
|
|
| 76 |
|
#44649: On page 76 there is this code "ruby script/generate scaffold product \ title:string description:text image_url:string"
It is expected that the user executes this line of code and the convention in the book has been to print such commands the user must type in as a bold brown font.
In the above line, it's printed as blue which is by previous convention in the book has been for examples.
The page also fails to make it clear that UNIX/OS X users need to remove the / mark as well, not just for windows users.--Garry Freemyer #44649: On page 76 there is this code "ruby script/generate scaffold product \ title:string description:text image_url:string"
It is expected that ...more...
|
P6.0
18-Aug-10
|
|
| 111 |
|
#49410: At the end of Iteration C1 after I click OK , I get the following error:
-----------------------------------------------
NoMethodError in Store#add_to_cart
Showing store/add_to_cart.html.erb where line #3 raised:
You have a nil object when you didn't expect it!
The error occurred while evaluating nil.items
Extracted source (around line #3):
1: <h2>Your Pragmatic Cart</h2>
2: <ul>
3: <% for item in @cart.items %>
4: <li><%=h item.title %></li>
5: <% end %>
6: </ul>
RAILS_ROOT: C:/InstantRails/rails_apps/depot
Application Trace | Framework Trace | Full Trace
app/views/store/add_to_cart.html.erb:3:in `_run_erb_47app47views47store47add_to_cart46html46erb'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:637:in `send'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:637:in `compile_and_render_template'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:365:in `render_template'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_view/base.rb:316:in `render_file'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1100:in `render_for_file'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:836:in `render_with_no_layout'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/layout.rb:262:in `render_without_benchmark'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:51:in `render'
C:/InstantRails/ruby/lib/ruby/1.8/benchmark.rb:293:in `measure'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:51:in `render'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1153:in `default_render'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1164:in `perform_action_without_filters'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:697:in `call_filters'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:689:in `perform_action_without_benchmark'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
C:/InstantRails/ruby/lib/ruby/1.8/benchmark.rb:293:in `measure'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/rescue.rb:199:in `perform_action_without_caching'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:678:in `perform_action'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in `cache'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/query_cache.rb:8:in `cache'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:677:in `perform_action'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in `send'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in `process_without_filters'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:685:in `process_without_session_management_support'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/session_management.rb:123:in `process'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:388:in `process'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:171:in `handle_request'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:115:in `dispatch'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:126:in `dispatch_cgi'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:9:in `dispatch'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/rails.rb:76:in `process'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/rails.rb:74:in `synchronize'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/rails.rb:74:in `process'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:159:in `process_client'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:158:in `each'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:158:in `process_client'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:285:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:285:in `initialize'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:285:in `new'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:285:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:268:in `initialize'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:268:in `new'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel.rb:268:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/configurator.rb:282:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/configurator.rb:281:in `each'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/configurator.rb:281:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/bin/mongrel_rails:128:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/lib/mongrel/command.rb:212:in `run'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.2-x86-mswin32/bin/mongrel_rails:281
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:489:in `load'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:489:in `load'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:342:in `new_constants_in'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:489:in `load'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/commands/servers/mongrel.rb:64
C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:342:in `new_constants_in'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require'
C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/commands/server.rb:39
C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
script/server:3
Request
Parameters:
{"authenticity_token"=>"587893cd7c8c43b02b548577ce3a36a82216a111",
"id"=>"4"}
Show session dump
---
flash: !map:ActionController::Flash::FlashHash {}
Response
Headers:
{"cookie"=>[],
"Cache-Control"=>"no-cache"}--aargo #49410: At the end of Iteration C1 after I click OK , I get the following error:
-----------------------------------------------
NoMethodError in St ...more...
|
P1.0
06-Jun-12
|
|
| 150 |
|
#48937: it can be found in controller of order in create action that is called when you place order
|
P7.0
13-Mar-12
|
|
|
168 |
#48235: In the first paragraph of section 11.4, the filename for the application controller is shown as "application.rb." I believe it should be "application_controller.rb."--Len Testa #48235: In the first paragraph of section 11.4, the filename for the application controller is shown as "application.rb." I believe it should be "appl ...more...
|
P7.0
08-Dec-11
|
|
|
190 |
#48240: In the listing at the top of page 190, for application.rb, I believe there's a 'begin' keyword missing as the first line of the set_locale method. The 'begin' keyword would match with the 'rescue' block later in that method. Leaving the 'begin' keyword out generates an error, while including it enables the script to work.--Len Testa #48240: In the listing at the top of page 190, for application.rb, I believe there's a 'begin' keyword missing as the first line of the set_locale met ...more...
|
P7.0
09-Dec-11
|
|
|
190 |
#48241: I believe the fourth line of the set_locale method should read:
locale_path = "#{LOCALES_DIRECTORY}/#{I18n.locale}.yml"
(notice there's a slash in the middle which does not appear in the book's version).--Len Testa #48241: I believe the fourth line of the set_locale method should read:
locale_path = "#{LOCALES_DIRECTORY}/#{I18n.locale}.yml"
(notice there's ...more...
|
P7.0
09-Dec-11
|
|
|
193 |
#48312: In the listing of index.html.erb, change the text between the h1 tags to read 'layout.title' instead of 'main.title'. Also change the submit_tag line to read 'layout.button.add'--Len Testa #48312: In the listing of index.html.erb, change the text between the h1 tags to read 'layout.title' instead of 'main.title'. Also change the submit_ ...more...
|
P7.0
16-Dec-11
|
|
|
194 |
#48242: The es.yml and en.yml files are missing colons in front of most of the symbols. For example, "side:" needs to be ":side:". The symbols for home, questions, news and contact also appear to need colons in front. --Len Testa #48242: The es.yml and en.yml files are missing colons in front of most of the symbols. For example, "side:" needs to be ":side:". The symbols for h ...more...
|
P7.0
09-Dec-11
|
|
| 194 |
|
#46284: If I put the code on that page into layouts/store.html.erb exactly as it is then current locale isn't selected in the locales select box. At least in Rails 2.3.10 the I18n.locale returns :en (symbol) and it doesn't match "en" string. I18n.locale.to_s fixed that.--Alexey Sorokin #46284: If I put the code on that page into layouts/store.html.erb exactly as it is then current locale isn't selected in the locales select box. At l ...more...
|
P7.0
21-Jan-11
|
|
| 279 |
|
#44645: Is it Rails 1.9 or Ruby 1.9? I don't think there is a Rails version 1.9. :-)
"Finally, Rails provides an ActiveSupport::Multibyte::Chars and an mb_chars on the String class. On Rails 1.9, mb_chars returns self, but on Ruby 1.8 it wraps the string in a multibyte proxy:"--Benjamin Halsted #44645: Is it Rails 1.9 or Ruby 1.9? I don't think there is a Rails version 1.9. :-)
"Finally, Rails provides an ActiveSupport::Multibyte::Chars an ...more...
|
P6.0
18-Aug-10
|
|
| 280 |
|
#46291: "Seems to us that gooses is a verb, not a plural noun."
I'm not sure if this is appropriate.--Andrew Grimm
Dave Thomas says: (Dave Thomas: Then I feel sorry)
|
P7.0
22-Jan-11
|
|
|
302 |
#46568: "ruby script/generate migration load_users_data"
should read:
"ruby script/generate migration load_user_data"--Allan Kinnaird
|
P4.0
12-Mar-11
|
|
| 489 |
|
#45840: The following is incorrect:
"If a before filter returns false, processing of the filter chain terminates, and the action is not run. A filter may also render output or redirect requests, in which case the original action never gets invoked."
A before_filter does not stop processing the filter chain on on return false any longer.
From release notes of Rails 2.0.1:
* Changed before_filter halting to happen automatically on render or redirect but no longer on simply returning false [David Heinemeier Hansson]
--Rob Christie #45840: The following is incorrect:
"If a before filter returns false, processing of the filter chain terminates, and the action is not run. A filt ...more...
|
P7.0
30-Nov-10
|
|
| 510 |
|
#44683: you cover the building of an XML template for products but the output generated is not consumable by ActiveResource
After a lot of research it seems that the output is missing the type="array" declaration for products.
It seems inconsistent and possibly a bug with Rails but it would be good if the book covered how to produce XML that would work with ActiveResource when using xml_builder
NoMethodError: undefined method `collect!' for #<Hash:0xb58a1208> is the error returned.--James West #44683: you cover the building of an XML template for products but the output generated is not consumable by ActiveResource
After a lot of research i ...more...
|
P6.0
23-Aug-10
|
|
| 648 |
|
#46924: it seems that the command "ruby script/plugin install ssl_requirement" does not work. The result of this is "Plugin not found: ["ssl_requirement"]" ?!
|
P7.0
21-Apr-11
|
|
| 736 |
|
#45070: The index, on page 736, refers to a "breakpointer command" that is supposedly described on page 273. However there is no such reference on that page, neither in the entire book. I suspect this index entry applied to an earlier version of the book (and Rails) and is now orphaned.--Julian Mehnle #45070: The index, on page 736, refers to a "breakpointer command" that is supposedly described on page 273. However there is no such reference on th ...more...
|
P7.0
16-Sep-10
|
|
| PDF |
Paper |
Description |
Found in |
Fixed in |
| 0 |
|
#44558: Notice, I'm not completely sure as I'm really new in ruby.
In the integration test "dsl_user_stories_test.rb" when defining the function user.has_a_cart_containing(*products)
the loop :
for item in cart.items
assert products.include?(item.product)
end
should be replaced by :
cart_products = cart.items.collect{|item| item.product}
for product in products
assert cart_products.include?(product)
end
in order to respect the function name--Philippe Van Eerdenbrugghe #44558: Notice, I'm not completely sure as I'm really new in ruby.
In the integration test "dsl_user_stories_test.rb" when defining the function us ...more...
|
P6.0
11-Aug-10
|
|
|
18 |
#41589: ERb is defined as "Embedded Ruby" on p. 18 but is not in the index, please add to index. P2.0 printing April 2009 Version: 2009-4-7, please add this printing to the selection dropdown for Errata as well, this is the paper version I have. Thanks.--M. Roxas #41589: ERb is defined as "Embedded Ruby" on p. 18 but is not in the index, please add to index. P2.0 printing April 2009 Version: 2009-4-7, please a ...more...
|
P1.0
21-Nov-09
|
|
|
114 |
#42012: To produce the sans-serif cart title shown in the "screen-shot", the css for .cart-title needs to be "font: bold 120% sans-serif;". ("120% bold" fails in both Safari 4.0.4 and Firefox 3.5.5)
I believe erratum notification #41977 is incorrect and should be removed - the item price is defined in cart_item.rb to be the product price times the quantity in the cart.--Allan Kinnaird #42012: To produce the sans-serif cart title shown in the "screen-shot", the css for .cart-title needs to be "font: bold 120% sans-serif;". ("120% bo ...more...
|
P4.0
05-Jan-10
|
|
| 137 |
|
#42022: For those who did the additional problem of linking using the book image. Here is the AJAX code to perform the same task as the new AJAX button:
<%= link_to_remote (image_tag(product.image_url), :url => { :action => 'add_to_cart',:method => :post, :id => product }) %>
Which is inserted between <div class="entry" and <h3><%= product.title %>--Andrew Szczepanski #42022: For those who did the additional problem of linking using the book image. Here is the AJAX code to perform the same task as the new AJAX butto ...more...
|
P1.0
08-Jan-10
|
|
| 151 |
|
#43712: In save_order method no check for cart's emptiness. i may go to checkout and press "empy cart" button. and after pressing "place order" button, an order is saved with no line_items.--Sam #43712: In save_order method no check for cart's emptiness. i may go to checkout and press "empy cart" button. and after pressing "place order" button ...more...
|
P6.0
11-Jun-10
|
|
| 171 |
|
#41917: As of the end of section 11.2 the admin_controller function is not working as intended in the case of erroneous logins.
Having a seperate terminal window to view messages I see the flow of login and password unhashed (is this a possible security hole?). Upon proper credentials, the user is sent to the /admin address. As intended. However upon improper credentials, the page is reloaded (intended) but the
flash.now[:notice] = "Invalid user/password combination"
is not kicking in.
I assumed that because of the lack of a views/layouts/admin.html.erb
file, this was occuring.
Upon creation of that file (a simple duplicate of users.html.erb - which in itself is raising a non-DRY issue)
the message appears.
I'm definitely a newbie. This is an interesting bug to leave lying around as an exercise (confirms learning).
But I'm also curious about the security hole and non-DRY issue at hand and resolving it.--Jerome Marchand #41917: As of the end of section 11.2 the admin_controller function is not working as intended in the case of erroneous logins.
Having a seperate t ...more...
|
P4.0
26-Dec-09
|
|
| 203 |
|
#41429: The i18n.t examples are leaving the colon out of the message, for example:
<%= form.label :name, I18n.t('checkout.name') + ":" %>
This should be consider bad i18n, since some languages may and do want to use different character for the colon, or leave it out altogether. It is also a sign for translators that it is used as a label.
--Niklas Laxström #41429: The i18n.t examples are leaving the colon out of the message, for example:
<%= form.label :name, I18n.t('checkout.name') + ":" %>
This sho ...more...
|
P1.0
14-Nov-09
|
|
| 204 |
|
#41924: On the use of UTF-8, HTML and Javascript...
Page 194, section 13.1 states:
"if you do this, just make sure that your editor is configured for UTF-8."
But then when dealing with the localisations for the checkout, the following is presented:
address: "Dirección"
pay_prompt: "Seleccione un m\xC3\xA9todo de pago"
which is a by-product of passing the values via javascript I suspect.
Presently, I literally have a situation where the i18n.rb file has the tilde-n inserted as such and renders (I saved it in UTF-8, no BOM encoding) . The es.yml file has a mix of HTML and hex characters (it does not take kindly to UTF-8 encoding). Three flavours for one objective; dispersive, if not un-DRYish.
This is a point for a someoneSays box to highlight some pitfalls. And maybe suggestions.
Above all, a language file in hexa is rather difficult to read, increases data entry problems, lengthens checking (what will the professional translator do? Upon creation is one thing, upon editing is another! [scent of bad coupling]) and gets moreso as its size increases. Needs to be avoided...--Jerome Marchand #41924: On the use of UTF-8, HTML and Javascript...
Page 194, section 13.1 states:
"if you do this, just make sure that your editor is configured f ...more...
Sam Ruby says: There's a bug report on Rails open on this: https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/2409-activerecord-double-escapes-error_messages_for
I plan to address this in the next edition.
|
P4.0
26-Dec-09
|
|
| 378 |
|
#43114: The section describing STI on page 377 lists the hierarchy of model objects.
There is followed by fugure 19.2 at the top ofpage 378 followed by the last model in the hierarchy (Manager). It would be less confusing if this was above the diagram so that it flows in with the other models used.
The confusion arose because I totally missed that model and had to re-track a bit.
Hope that makes sense--James West #43114: The section describing STI on page 377 lists the hierarchy of model objects.
There is followed by fugure 19.2 at the top ofpage 378 followed ...more...
|
P5.0
06-May-10
|
|
| 412 |
|
#42273: In the discussion of how to build a callback class and express it throughout all models, I think that a critical question is not addressed:
(1) how do we get this file "sourced" into the Rails runtime. If you put it in lib as a module does it automatically get loaded up? How can we get it to run as the environment boots up. The example source file is given as a stand-alone script.
(2) It appears that we're being encouraged to monkey-patch ActiveRecord::Base. While the ability to do this is one of the amazing joys of Ruby, it might be good to explain why this may or may not be a good idea. Many a tweet has gone out on the difficulty monkeypatching has introduced in code-sharing / debugging.--Steven Harms #42273: In the discussion of how to build a callback class and express it throughout all models, I think that a critical question is not addressed:
...more...
|
P5.0
08-Feb-10
|
|
| 506 |
|
#43519: link_to(:action => :delete, :confirm => "Are you sure?") will prevent spiders from executing the delete request, because a GET instead of (POST) DELETE request will be sent to the server & routing will ignore the request / raise error / show a confirmation page. #43519: link_to(:action => :delete, :confirm => "Are you sure?") will prevent spiders from executing the delete request, because a GET instead of (POS ...more...
|
P6.0
31-May-10
|
|
| 523 |
|
#42994: In figure 23.1 I'd imagine that #5 should actually reference a create action rather than a save action for it to follow convention.--Zack Hubert
|
P5.0
27-Apr-10
|
|
| 560 |
|
#44050: The last part of the section on caching needs cleanup or more explanation:
ActionController::Base.cache_store = <one of the following>
...
:mem_cache_store, "localhost" ActionController::Base.cache_store = MyOwnStore.new("parameter")
This stores fragments in a memcached server. #44050: The last part of the section on caching needs cleanup or more explanation:
ActionController::Base.cache_store = <one of the following>
. ...more...
|
P6.0
11-Jul-10
|
|
| 563 |
|
#42439: I think that this chapter is off from the general character and tenor of the rest of the book. It feels very much "bolted-on."
The chapter opens strongly, setting up a tri-partite discussion framework and a one-sentence characterization of each of the parts (Prototype, Scriptaculous, RJS). What I consider to be one of the highlights of pragprog books is the way that examples and working assignments are given, and often. This chapter delivers on the example on the second page; however the "how to build up to this" is not given.
Now you MIGHT think this is acceptable (oh you're twenty-someodd chapters in, you can make this example work), but didn't the reader just PAY to have you be verbose and teach? Further, we're learning something new, AJAX. We're learning it without any context, it seems an unfair leap to expect that the reader will be able to execute the harness application flawlessly such that the rest of the lesson might be applied. Perhaps a github link to a baseline project would be helpful if you're committed to not adding text.
Furthermore, no context is given in the code examples. It looks to me like there's some pagination-fu at the base of the view. Where did that chant come from?
I don't expect this chapter to be a be-all-end-all description of Ajax and Rails, but the presentation on this topic in this book has pushed me to buy the ORA "Ajax on Rails" book. #42439: I think that this chapter is off from the general character and tenor of the rest of the book. It feels very much "bolted-on."
The chapte ...more...
|
P5.0
11-Mar-10
|
|
| 632 |
|
#42401: The description of nested resources in ActiveResource is missing a critical piece. The LineItem model in depot_client is not shown, most importantly the special self.site path with orders/:order_id.
Also the LineItemsController in depot_t does not properly return only the line items for the specified order. Instead it returns all line items for all orders.--Scott Johnson #42401: The description of nested resources in ActiveResource is missing a critical piece. The LineItem model in depot_client is not shown, most impor ...more...
|
P5.0
02-Mar-10
|
|
| 657 |
|
#41595: The instructions for creating the empty git repository assume git has been installed on the git server. But the reader was not told to install git. "$ git --bare init" will fail if git is not installed. This was found in p3.0, 2009-9-21 PDF.--Jamie Allen #41595: The instructions for creating the empty git repository assume git has been installed on the git server. But the reader was not told to instal ...more...
|
P1.0
22-Nov-09
|
|