python: remove redundant is_string_type