PY3: decode -> encode