use DelayedCall.active() instead DelayedCall.called, to support cancelled tasks

This commit is contained in:
Pablo Hoffman 2009-11-26 16:10:28 -02:00
parent 88417a3ed1
commit c0f1c8de04
1 changed files with 1 additions and 1 deletions

View File

@ -40,5 +40,5 @@ class CloseSpider(object):
def spider_closed(self, spider):
self.counts.pop(spider, None)
tsk = self.tasks.pop(spider, None)
if tsk and not tsk.called:
if tsk and tsk.active():
tsk.cancel()