def s3_str(s, encoding="utf-8"):
    """
        Convert an object into a str

        Args:
            s: the object
            encoding: the character encoding
    """

    if type(s) is str:
        return s
    elif type(s) is bytes:
        return s.decode(encoding, "strict")
    else:
        return str(s)