arthur/arthur.py
def __validate_args(task_id, backend, category, backend_args):
        """Check that the task arguments received are valid"""

        if not task_id or task_id.strip() == "":
            msg = "Missing task_id for task"
            raise ValueError(msg)

        if not backend or backend.strip() == "":
            msg = "Missing backend for task '%s'" % task_id
            raise ValueError(msg)

        if backend_args and not isinstance(backend_args, dict):
            msg = "Backend_args is not a dict, task '%s'" % task_id
            raise ValueError(msg)

        if not category or category.strip() == "":
            msg = "Missing category for task '%s'" % task_id
            raise ValueError(msg)
def __validate_args(task_id, backend, category, backend_args):
        """Check that the task arguments received are valid"""

        if not task_id or task_id.strip() == "":
            msg = "Missing task_id for task"
            raise ValueError(msg)

        if not backend or backend.strip() == "":
            msg = "Missing backend for task '%s'" % task_id
            raise ValueError(msg)

        if backend_args and not isinstance(backend_args, dict):
            msg = "Backend_args is not a dict, task '%s'" % task_id
            raise ValueError(msg)

        if not category or category.strip() == "":
            msg = "Missing category for task '%s'" % task_id
            raise ValueError(msg)
Check that the task arguments received are valid