def METHOD_NAME(config, task, schema_key="schema_file"):
    """Verify the task definition.
    Args:
        config (dict): the running config
        task (dict): the running task
        schema_key: the key in `config` where the path to the schema file is. Key can contain
            dots (e.g.: 'schema_files.file_a')
    Raises:
        TaskVerificationError: if the task doesn't match the schema
    """
    schema_path = config
    schema_keys = schema_key.split(".")
    try:
        for key in schema_keys:
            schema_path = schema_path[key]
        task_schema = load_json_or_yaml(schema_path, is_path=True)
        log.debug("Task is verified against this schema: {}".format(task_schema))
        verify_json_schema(task, task_schema)
    except (KeyError, OSError) as e:
        raise TaskVerificationError("Cannot verify task against schema. Task: {}.".format(task)) from e