'Dynamic chord size in a celery chain

Here is the workflow I'm trying to achieve with celery:

* download a big file
* split it in chunks (to files)
* process each chunk independantly
* notifications once all each chunks are processed.
from celery import chunks
url = "http://myurl.com"
process = (download_file.s(url) | split_chunk.s() | process_chunk.chunks( ????) | notify.s()).delay()

I can't see a way of having a dynamic size parameter to pass to the chunks method.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source