The release notes of Crystal 0.34 say "Having as much as possible portable code is part of the goal of the std-lib. One of the areas that were in need of polishing was how Errno and WinError were handled. The Errno and WinError exceptions are now gone, and were replaced by a new hierarchy of exceptions."
So I have modified
rescue ex: Errno
raise ErrorException.new(ex.message, NONE) if ex.errno == Errno::EPIPE
to
rescue ex: IO::Error
raise ErrorException.new(ex.message, NONE) if ex.os_error == Errno::EPIPE