str_utils.py has functions for converting strings from one type to another. It also has a TypeVar called NonBinaryStr, which is like AnyStr except that it doesn't allow bytes.