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

download all artifacts with concurrent tasks #288

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

johnnychen94
Copy link

It takes quite a long time to wait for each artifact to be downloaded if it's in a sequential manner, so I figure it might be worth adding concurrent support here.

But I'm not sure if this is implemented well. For instance, the downloading tasks can't be correctly killed if I hit Ctrl-C. Does Julia have a "standard" way of doing so? I found https://discourse.julialang.org/t/stop-terminate-a-sub-task-started-with-async/32193 but am not sure if that's okay to use.

verbose && @info "launch $concurrency concurrent downloading tasks"
wait(taskpool)
@sync for _ in 1:concurrency
@async begin
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For new code I recommend against the use of @async and strongly prefer Threads.@spawn.

@giordano
Copy link
Member

giordano commented Jan 8, 2023

Side note: download_all_artifacts isn't used anywhere as far as I can tell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants