You may find `six.indexbytes` more pleasant