Creating this topic to catch any typos and bugs in the 1st Edition of Dart Apprentice: Beyond the Basics.
PDF, Page 23, Paragraph Matching the Beginning and End, first example:
final numbers = RegExp('r[0-9]');
The r
symbol should be in front of the string:
final numbers = RegExp(r'[0-9]');
PDF, Page 57, Paragraph Calling Super Last in an Initializer List, the example:
class SomeChild extends SomeParent {
SomeChild(double height, double width, String name)
: _width = width, // initializer
: _height = height, // initializer
super(name); // super
final double _width;
final double _height;
}
Line 4:
: _height = height, // initializer
Looks like we don’t need that colon before the _height
variable since it breaks the initializer list syntaxis.
PDF, Page 72, Paragraph Separating Business Logic From Infrastructure, the image with the scheme has left side blue circle block named Business Login — I think it should be Business Logic instead:
@eshfield Thank you for all of your error reports! I didn’t have my notifications set up correctly for this book, so I am just seeing your posts today.
For the truncated text in the How to Read This Book section, I’m not sure what the problem is. My PDF version isn’t truncated. Maybe @jellodiil can give some help.
Yes, thank you! Updated.
That’s right. Thank you. I’ve updated the chapter text for the online version.
@eshfield I can’t make more than three consecutive replies, so I’m posting the following as an edit to my previous reply:
You’re right again. Thank you. I’m requesting an updated image from the illustration team.
@suragch I’m glad that my meticulousness is useful here
I have a little bit of another observations that I couldn’t post earlier due the three consecutive replies limit.
- PDF, Page 96, Paragraph Storing a Tree in a List
Looks like the figure with the tree has element #3 (value of5
) and #4 (value of0
) swapped:
Another tree figures in this chapter have the correct order:
- PDF, Page 129
This is not the Continue button highlighted at the image:
- PDF, Page 135 and 136
Now, add the following validation method below main :
Add a few more validation methods below main :
Is it correct to name that functions as methods? This is just a regular functions, not in the class definition scope.
- PDF, Page 167
Looks like the error
message for the SocketException
doesn’t have the prefix SocketException:
— only Failed host lookup: 'jsonplaceholder.typicode.com'
(using Dart 2.19)
Page 175, the last line before Using a Stream paragraph:
The chapter will finish by teaching you how to make your own steams
Steampunk is fun
PDF, Page 187, Writing the Code:
I think it would be worth to mention that you need to ensure you have import 'dart:async';
line to have the ability to use the StreamController
at this example
I’m glad that my meticulousness is useful here
Very useful!
- PDF, Page 96, Paragraph Storing a Tree in a List
Looks like the figure with the tree has element #3 (value of5
) and #4 (value of0
) swapped:
Yes, thank you. I’ve requested an updated image from the illustrations team.
- PDF, Page 129
This is not the Continue button highlighted at the image:
The image is correct in my PDF version and in the online version and in the current book repo and the recent repo history, so I’m not sure why your PDF shows the wrong image. Did you download the PDF from the Kodeco website? What renderer are you using to view the PDF content?
Is it correct to name that functions as methods? This is just a regular functions, not in the class definition scope.
Good point. I’ve updated the wording here and several other places in the article.
Looks like the
error
message for theSocketException
doesn’t have the prefixSocketException:
— onlyFailed host lookup: 'jsonplaceholder.typicode.com'
(using Dart 2.19)
This is also true for Dart 2.18 (which is what the book should be using). I’ve updated the error message.
My PDF version is from Kodeco website and I just open it in Chrome browser to read. Looks like I have some local problems on my machine with PDF rendering (recalling my first issue with truncated text at the beginning of the book) — sorry for that false alarms.
Steampunk is fun
Haha, I don’t know much about that, but streams are too. I’ll make the update. Thanks.
I think it would be worth to mention that you need to ensure you have
import 'dart:async';
line to have the ability to use theStreamController
at this example
I agree. I’m now having the reader replace the entire main
function and included the import.
This is not the erratum — just a note.
What is the point to give every chapter the author subtitle when all chapters in both Dart Apprentice books have same writer? I have nothing against the vanity and in no way I don’t want to underestimate your merit in the colossal work of writing these books — they rightfully bear your name on the covers. But as you taught us with DRY principle we don’t like the unjustified repetitions, don’t we?
Yes, I agree. I think I actually even saw this same advice in our book writing guidelines. It’s not quite true that it is the same author for every chapter in both books, though. Chapters 2-6 of Dart Apprentice: Fundamentals were based on content from Matt Galloway’s work in Swift Apprentice. Thus, he is a credited author in those chapters. However, this doesn’t apply to Dart Apprentice: Beyond the Basics and the author name should be removed at the beginning of the chapters.
@jellodiil Can you make the change to remove the author name at the beginnings of the chapters in DABB? Also, if you want to remove the author names in the chapters in DAF, I made an update in the acknowledgements of DAF specifying exactly which chapters were based on Matt’s work. I thought you had removed the chapter author names before, but when I just downloaded the DAF PDF just now they were still there.
Business Logic and Binary Tree images are now updated.
For the online version we can’t remove the author name easily (and from the above conversations, it seems that that’s where the PDF is generated from), it gets added automatically whether it is the same author or individual authors.
But it’s a good feedback—we can consider whether showing a single author is necessary or not.