Skip to content

Commit 8ff7177

Browse files
committed
Merge branch 'master' into synack
2 parents dea4fc3 + aae9d28 commit 8ff7177

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

celery/backends/mongodb.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ def _store_result(self, task_id, result, status, traceback=None):
128128
'date_done': datetime.utcnow(),
129129
'traceback': Binary(self.encode(traceback)),
130130
'children': Binary(self.encode(self.current_task_children()))}
131-
self.collection.save(meta, safe=True)
131+
self.collection.save(meta)
132132

133133
return result
134134

@@ -155,7 +155,7 @@ def _save_group(self, group_id, result):
155155
meta = {'_id': group_id,
156156
'result': Binary(self.encode(result)),
157157
'date_done': datetime.utcnow()}
158-
self.collection.save(meta, safe=True)
158+
self.collection.save(meta)
159159

160160
return result
161161

@@ -187,7 +187,7 @@ def _forget(self, task_id):
187187
# By using safe=True, this will wait until it receives a response from
188188
# the server. Likewise, it will raise an OperationsError if the
189189
# response was unable to be completed.
190-
self.collection.remove({'_id': task_id}, safe=True)
190+
self.collection.remove({'_id': task_id})
191191

192192
def cleanup(self):
193193
"""Delete expired metadata."""

celery/canvas.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ def from_dict(self, d):
298298
tasks = d['kwargs']['tasks']
299299
if d['args'] and tasks:
300300
# partial args passed on to first task in chain (Issue #1057).
301-
tasks[0]['args'] = d['args'] + tasks[0]['args']
301+
tasks[0]['args'] = tasks[0]._merge(d['args'])[0]
302302
return chain(*d['kwargs']['tasks'], **kwdict(d['options']))
303303

304304
@property
@@ -409,7 +409,7 @@ def from_dict(self, d):
409409
if d['args'] and tasks:
410410
# partial args passed on to all tasks in the group (Issue #1057).
411411
for task in tasks:
412-
task['args'] = d['args'] + task['args']
412+
task['args'] = task._merge(d['args'])[0]
413413
return group(tasks, **kwdict(d['options']))
414414

415415
def __call__(self, *partial_args, **options):

0 commit comments

Comments
 (0)