Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Core feature] map_task to support ContainerTask #6277

Open
2 tasks done
litaifang opened this issue Feb 26, 2025 · 1 comment
Open
2 tasks done

[Core feature] map_task to support ContainerTask #6277

litaifang opened this issue Feb 26, 2025 · 1 comment
Labels
enhancement New feature or request untriaged This issues has not yet been looked at by the Maintainers

Comments

@litaifang
Copy link

litaifang commented Feb 26, 2025

Motivation: Why do you think this is important?

Being able to use any arbitrary docker to execute a task (i.e., ContainerTask) is an important feature in many bioinformatic workflow schemes. However, ContainerTask is currently not supported by map tasks.
This and this were never merged so this capability never made it into flyte.
It'd be great to be able to use map_task to spin out ContainerTasks in parallel.

Goal: What should the final outcome look like, ideally?

Something like this should work as intended:

@dynamic
def map_task_of_container_task(...) -> None:
    inner_task = ContainerTask(
        name="inner-task-bring-your-own-container",
        input_data_dir="/var/inputs",
        output_data_dir="/var/outputs",
        inputs=kwtypes(...),
        outputs=kwtypes(...),
        image="docker.io/ubuntu:latest",
        command=["sh", "-c", ...],
    )
    map_task(inner_task)(map_input=[...])

Describe alternatives you've considered

Alternatively I can just loop over the ContainerTask in a dynamic, but it doesn't have the benefits of a map_task.

Propose: Link/Inline OR Additional context

There were two pull requests attempting to add this feature but were never merged: this and this.

Are you sure this issue hasn't been raised already?

  • Yes

Have you read the Code of Conduct?

  • Yes
@litaifang litaifang added enhancement New feature or request untriaged This issues has not yet been looked at by the Maintainers labels Feb 26, 2025
Copy link

welcome bot commented Feb 26, 2025

Thank you for opening your first issue here! 🛠

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request untriaged This issues has not yet been looked at by the Maintainers
Projects
Status: Backlog
Development

No branches or pull requests

1 participant