By Developers, For Developers

Historical errata for The dRuby Book

PDF PgPaper PgTypeDescriptionFixed onComments
7TYPO

Under “1.2 Building the Reminder Application,” the three methods of the Reminder class are listed: “It has three methods: Add, delete, and to_a.” The “Add” method described should be called “add.”

9ERROR

My “r = DRbObject.new_with_uri(‘druby://localhost:12345’)” call hung, but using a —noreadline option to irb didn’t fix it (and I didn’t need the option for the first example, so I think I’m OK without it).

I fixed the hang. After starting the server by calling:
s = DRb.start_service(‘druby://localhost:12345’, front)

I did a:
s.thread.join

After doing this, the hanging client returned and the example worked fine.

I am running Ruby 1.9.2p290 on OSX 10.7.3

221TYPO

Page 221 - CG instead of GC — from customer feedback.

136ERROR

The figure 36 description is reversed. It should say down is equivalent to take and up is equivalent to write. Text currently says:

Figure 36—The implementation of a semaphore using TupleSpace. The down method is equivalent to write, and the up method is equivalent to take.

129TYPO

Duplicated sentence on second and third paragraph:

“Consider a program … completed phase n.”

63TYPO

change:
>> str.id
=> 358800978
to:
>> str.id
=> 358800978

34-39TYPO

code examples miss “require ‘Date’” statement at the top, otherwise error "…/shipping_notify.rb:60:in `

’: uninit
ialized constant Date (NameError)
occurs.

53TYPO

In the code example, it says “oops”, though other lines has “oops,” and “oops.”. These comma and period are not necessary.

69TYPO

From
=>> #

To

=> #

73TYPO

From

DRBUnknown#reload

To

DRbUnknown#reload

82TYPO

exit - Terminate the thread.
wakeup - Change the thread in running mode.
run - Get the thread into running mode. Switch thread.
raise - Raise exception to the thread.

The verb should ends with “s” (eg: Terminates) to be consistent with method explanations in other pages

130TYPO

At tsstruct.rb

From

ensure @ts.write(tuple) if tuple

To

ensure
@ts.write(tuple) if tuple

162TYPO

From

Rwiki (a dRuby-powered wiki)

To

RWiki (a dRuby-powered wiki)

162TYPO

From

similar to Rail’s view helper)

To

similar to Rails’ view helper)

173ERROR
  1. fork.rb

result = 0
pid = fork do
result += 1
end Process::waitpid(pid) p result

Missing indentation

235TYPO

From

>> >osx[:msg] = ‘linux box to osx’

To

>> osx[:msg] = ‘linux box to osx’

239TYPO

From

Changes URI to become method call to GW and W rap

To

Changes URI to become method call to GW and Wrap

86ERROR

Explanation about Thread.exclusive and Thread.critical is wrong
forums.pragprog.com/forums/198/topics/10553

71TYPO

In the second-to-last paragraph, “When you want to include it in a instance, ” should read “…an instance”.

74TYPO

Last paragraph: “Why do we need such functionalities?” should read “… functionality?”

81TYPO

Should the run state have double quotes around it?

xiiiTYPO

In the third paragraph, last sentence, you have used the word “discovering” when you wanted to use the word “discover”. It should say, “… as you read and discover new things along the way.”.

33ERROR

In the page 33, IDL is explained as Interactive Data Language, instead Interface Definition Language.

Categories: