Terminal freezes with beach ball on High Sierra
You are likely being hit by a macOS 10.13.2 kernel bug, described here, and exposed pretty regularly by htop, described here.
Supposedly, macOS 10.13.4 beta has a kernel fix, and version 2.10.0 of htop was released to work around this bug.