Ruby <-> Python: handling of UTF-8 encodings comparison