def METHOD_NAME(cls, crawler, *args, **kwargs):
    spider = super().METHOD_NAME(crawler, *args, **kwargs)
    crawler.signals.connect(spider.spider_idle, signal=scrapy.signals.spider_idle)
    return spider