Only the client can unambiguously know what they intended the encoding to be.  This library method needs bytes, it *is* the output method.

See for example https://github.com/facebook/tornado/blob/master/tornado/iostream.py#L212 (`bytes_type` is either `bytes` or `str` depending on the Python version).

Re: your 2nd point, it might be clearer if `_command` didn't return a concatenated string including `body`.  A tuple perhaps?

Also, for correctness, arguable the `str` assertion should happen *before* `_command` is called.   `pub` and `mpub` and other higher level command methods need to calculate correct byte lengths.  Even though it would probably still barf on an assertion here anyway, eventually...