def is_non_fatal_issue()

in src/local_gpu_verifier/src/verifier/exceptions/utils.py [0:0]


def is_non_fatal_issue(error):
    """ The function to check if the given error is non fatal or not.

    Args:
        error (Exception): any exception that may be raised.

    Returns:
        [bool]: returns True if the error is non fatal. Otherwise returns
                False.
    """

    if isinstance(error, type(NVMLError(NVML_ERROR_UNINITIALIZED))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_TIMEOUT))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_RESET_REQUIRED))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_IN_USE))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_MEMORY))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_NO_DATA))) or \
       isinstance(error, type(NVMLError(NVML_ERROR_INSUFFICIENT_RESOURCES))) or \
       isinstance(error, NonceMismatchError) or \
       isinstance(error, TimeoutError):
       return True

    return False