def METHOD_NAME(
    self, sobject_name: T.Optional[str], num_as_str: T.Union[str, int]
):
    self.sobject_name = sobject_name
    try:
        self.target = self.gap = int(num_as_str)
    except (TypeError, ValueError):
        raise exc.TaskOptionsError(f"{num_as_str} is not a number")