-
Notifications
You must be signed in to change notification settings - Fork 177
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
hangs for 2 minutes while storing buildx in cache #293
Comments
hmmm moving this out of vpn didn't fix the problem, not i'm even more confused. need to dig in more. |
(i think there's some sort of caching issue at play that made it seem like doing it outside of vpn fixed it) |
OK, i'm 90% sure the problem is this line -- https://github.com/docker/actions-toolkit/blob/9282d3e13b5c0ff919207d30e173b0504a8cd8df/src/buildx/install.ts#L334 if i comment out that line, the problem goes away. when it uploads the file, GHA does some sort of work in the background to keeps the step open. maybe the cache save is just slow? |
(updated the description to make it clear this is not a vpn problem, but now i don't really know why i can consistently reproduce this in one repo but not others) |
what if we move the cache.save() into the post part of the job? i think that's technically more correct anyway -- it's what other github actions stuff does |
i mocked this up while investigating docker/setup-buildx-action#293 i guess this is SLIGHTLY better in that it makes the 2 minutes pause that i'm seeing happen AFTER tests, but the pause is still there. Signed-off-by: Nick Santos <nick.santos@docker.com>
posted this change that at least isolates the weird behavior - docker/actions-toolkit#241 |
i mocked this up while investigating docker/setup-buildx-action#293 i guess this is SLIGHTLY better in that it makes the 2 minutes pause that i'm seeing happen AFTER tests, but the pause is still there. Signed-off-by: Nick Santos <nick.santos@docker.com>
i mocked this up while investigating docker/setup-buildx-action#293 i guess this is SLIGHTLY better in that it makes the 2 minutes pause that i'm seeing happen AFTER tests, but the pause is still there. Signed-off-by: Nick Santos <nick.santos@docker.com>
ok, we figured out the root cause. we don't think this is a setup-buildx-action issue. writing down the problem in case we see it again: github actions uses a layered cache approach. each branch can write to exactly for more info on this, see: this works really well if you run a github action on both pull and push (which the repo where we were having this problem only ran setup-buildx-action on pull, not on push. this leads to weird and pathological cache behavior, because every branch starts i still think it might make sense to do move the cache save call until the post-action step (like other github actions do), but let's close this issue. |
Contributing guidelines
I've found a bug, and:
Description
setup-buildx-action consistently hangs for 2 minutes.
Expected behaviour
No pause
Actual behaviour
pause
Repository URL
private
Workflow run URL
private
YAML workflow
Relevant snippet:
Workflow logs
(Note the long pause between inspecting the builder and the node action completing)
BuildKit logs
No response
Additional info
@crazy-max spent some time poking at this and couldn't figure it out. but some additional data points:
The text was updated successfully, but these errors were encountered: