X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=api%2Fresources%2Fv2%2Ftasks.py;h=885a190c6c040ef0721e8770be6191801e88e1b1;hb=e78324bf2672a694f460e953373f18729c476e8d;hp=9790d764054f3176f7b2a824980ff6b39216b302;hpb=e1c93d07ef87efc4e891ad8ccdf2e051b38c0142;p=yardstick.git diff --git a/api/resources/v2/tasks.py b/api/resources/v2/tasks.py index 9790d7640..885a190c6 100644 --- a/api/resources/v2/tasks.py +++ b/api/resources/v2/tasks.py @@ -1,3 +1,11 @@ +############################################################################## +# Copyright (c) 2017 Huawei Technologies Co.,Ltd. +# +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Apache License, Version 2.0 +# which accompanies this distribution, and is available at +# http://www.apache.org/licenses/LICENSE-2.0 +############################################################################## import uuid import logging from datetime import datetime @@ -106,7 +114,8 @@ class V2Task(ApiResource): if project.tasks: LOG.info('update tasks in project') - new_task_list = project.tasks.split(',').remove(task_id) + new_task_list = project.tasks.split(',') + new_task_list.remove(task_id) if new_task_list: new_tasks = ','.join(new_task_list) else: