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

Fallback to psutil when /proc/.../children isn't present #1864

Closed
wants to merge 1 commit into from

Conversation

Kamori
Copy link

@Kamori Kamori commented May 30, 2020

I'm developing a project using Ubuntu 18.04 on Windows WSL2. For some reason /proc/{pid}/task/{pid}/children isn't available. When this happened, we return with no good explanation why.

To make sure we don't break current users, I added a fallback to psutil to discover the children and kill them and move on.

Hope this helps others who use WSL2

Edit: This affects the live reloading feature

@Tronic
Copy link
Member

Tronic commented May 31, 2020

The code patched here is removed entirely in #1827 which rewrites the autoreloader kill logic (i.e. the autoreloader signals the main server, which then signals its children, avoiding the need to kill all children).

@Kamori Would you mind testing that PR to see if it also works for you?

@ahopkins
Copy link
Member

ahopkins commented Jun 3, 2020

@Kamori Thanks for the PR. I am placing on hold until we see if this is still necessary once #1827 is merged.

@Kamori
Copy link
Author

Kamori commented Jun 4, 2020

Sorry for the delay. I'll test this when I can. Hopefully tomorrow

@Kamori
Copy link
Author

Kamori commented Jun 7, 2020

First test seems to work well! I'm gonna do a bit of development today to make sure I don't run into any issues. I'll close this ticket out if all looks good. Thanks everyone!

@Kamori Kamori closed this Jun 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants