mirror of
https://framagit.org/framasoft/framaspace/argos.git
synced 2025-04-28 09:52:38 +02:00
🐛 — Fix strange and buggy behavior
This commit is contained in:
parent
06f8310505
commit
be90aa095a
1 changed files with 3 additions and 1 deletions
|
@ -164,6 +164,7 @@ class ArgosAgent: # pylint: disable-msg=too-many-instance-attributes
|
|||
logger.info("Received %i tasks from the server", len(data))
|
||||
|
||||
req_groups = {}
|
||||
_tasks = []
|
||||
for _task in data:
|
||||
task = Task(**_task)
|
||||
|
||||
|
@ -187,6 +188,7 @@ class ArgosAgent: # pylint: disable-msg=too-many-instance-attributes
|
|||
"method": task.method,
|
||||
"request_data": task.request_data,
|
||||
}
|
||||
_tasks.append(_task)
|
||||
|
||||
requests = []
|
||||
for group, details in req_groups.items():
|
||||
|
@ -196,7 +198,7 @@ class ArgosAgent: # pylint: disable-msg=too-many-instance-attributes
|
|||
await asyncio.gather(*requests)
|
||||
|
||||
tasks = []
|
||||
for task in data:
|
||||
for task in _tasks:
|
||||
tasks.append(self._complete_task(task))
|
||||
|
||||
if tasks:
|
||||
|
|
Loading…
Reference in a new issue