def strip_suffix(s, suffix):
    """Remove suffix frm the end of s
    is s = "aaa.gpg" and suffix = ".gpg", return "aaa"
    if s is not a string return None
    if suffix is not a string, return s

    :param str s: string to modify
    :param str suffix: suffix to remove

    :rtype: Optional[str]=None
    """
    if not isinstance(s, str):
        return None
    if not isinstance(suffix, str):
        return s
    if s.endswith(suffix):
        return s[: -len(suffix)]
    return s