@task
def build_sitemaps():
 tasks = [build_locale_sitemap.si(locale) for locale in settings.MDN_LANGUAGES]
 post_task = build_index_sitemap.s()
 chord(header=tasks, body=post_task).apply_async(max_retries=300, interval=1)

@ task def build_sitemaps ( ) : tasks = [ build_locale_sitemap . si ( locale ) for locale in settings . MDN_LANGUAGES ] post_task = build_index_sitemap . s ( ) chord ( header = tasks , body = post_task ) . apply_async ( max_retries = 300 , interval = 1 )
build and save sitemap files for every mdn language and as a callback save the sitempa index file as well .