I suggest adding a hint somewhere in the book that in this environment, threads have very limited stack space. So you may often encounter stack overflow problems. The stack size can be specified in this way:
thread::Builder::new().stack_size(4096).spawn(|| {
// do something
})?;