Skip to content
This repository was archived by the owner on Apr 12, 2018. It is now read-only.

Commit 39ca2ef

Browse files
committed
Fix querysets.workflow.WorkflowExecutionQuerySet.filter arguments #44
1 parent ac547ac commit 39ca2ef

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

swf/querysets/workflow.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -412,8 +412,7 @@ def list_workflow_executions(self, status, *args, **kwargs):
412412
# MANDATORY kwarg, when boto.swf.list_open_workflow_executions awaits a
413413
# `oldest_date` mandatory arg.
414414
if status == WorkflowExecution.STATUS_OPEN:
415-
oldest_date = kwargs.pop('start_oldest_date')
416-
args = args + (oldest_date,)
415+
kwargs['oldest_date'] = kwargs.pop('start_oldest_date')
417416

418417
try:
419418
method = 'list_{}_workflow_executions'.format(statuses[status])
@@ -561,9 +560,12 @@ def filter(self, domain=None,
561560
start_oldest_date = datetime_timestamp(past_day(oldest_date))
562561
return [self.to_WorkflowExecution(domain, wfe) for wfe in
563562
self._list_items(
564-
status,
565-
self.domain.name,
566563
*args,
564+
domain=self.domain.name,
565+
status=status,
566+
workflow_id=workflow_id,
567+
workflow_name=workflow_type_name,
568+
workflow_version=workflow_type_version,
567569
start_oldest_date=int(start_oldest_date),
568570
tag=tag,
569571
**kwargs

0 commit comments

Comments
 (0)