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

fix docker leak #4970

Merged
merged 1 commit into from
Nov 13, 2024
Merged

fix docker leak #4970

merged 1 commit into from
Nov 13, 2024

Conversation

rbren
Copy link
Collaborator

@rbren rbren commented Nov 13, 2024

End-user friendly description of the problem this fixes or functionality that this introduces

  • Include this change in the Release Notes. If checked, you must provide an end-user friendly description for your change below
    no changelog

Give a summary of what the PR does, explaining any non-trivial design decisions

Docker images are getting left hanging because the atexit isn't registering properly. Needed to fix some imports to make it work

Here's the relevant atexit:

atexit.register(remove_all_runtime_containers)

When we import inside of get_runtime_cls, this isn't registered in the main thread, so it gets left hanging


Link of any specific issues this addresses

Fixes #4967


To run this PR locally, use the following command:

docker run -it --rm   -p 3000:3000   -v /var/run/docker.sock:/var/run/docker.sock   --add-host host.docker.internal:host-gateway   -e SANDBOX_RUNTIME_CONTAINER_IMAGE=docker.all-hands.dev/all-hands-ai/runtime:62c2a46-nikolaik   --name openhands-app-62c2a46   docker.all-hands.dev/all-hands-ai/openhands:62c2a46

@rbren rbren marked this pull request as ready for review November 13, 2024 15:50
@xingyaoww xingyaoww merged commit f55ddbe into main Nov 13, 2024
12 checks passed
@xingyaoww xingyaoww deleted the rb/docker-leak branch November 13, 2024 16:23
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.

[Bug]: Runtime Leak
2 participants