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

chromium uses 100% cpu in dev container and tests timeout #3781

Open
valankar opened this issue Sep 25, 2024 · 11 comments
Open

chromium uses 100% cpu in dev container and tests timeout #3781

valankar opened this issue Sep 25, 2024 · 11 comments
Labels
help wanted Extra attention is needed

Comments

@valankar
Copy link

Description

I'm trying out the dev container and just running a test (e.g. test_tabs.py). From what I can tell, the chromium process just go to 100% cpu, and after some minutes the test times out.

top output during test run:

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND
 750002 valankar  20   0 1156.2g  79100  62088 R 100.0   1.0   3:52.08 chromium
 749803 valankar  20   0   32.6g 176452 149428 S   9.3   2.2   0:21.49 chromium
 750067 valankar  20   0   32.6g  46400  31736 S   9.3   0.6   0:20.86 chromium

Any idea what is wrong here or how to debug?

@valankar
Copy link
Author

What vscode looks like during test run:

image

@valankar
Copy link
Author

And after the timeout:

image

@rodja
Copy link
Member

rodja commented Sep 30, 2024

This may be a duplicate of #3066. Can you check?

@falkoschindler falkoschindler added the question Further information is requested label Sep 30, 2024
@valankar
Copy link
Author

That looks like something else. In my case it is chromium using up cpu, not a nicegui app. Basically, I'm trying to setup the devcontainer environment to make changes to nicegui code. But when I try any of the nicegui tests they just fail as above.

@falkoschindler falkoschindler removed the question Further information is requested label Sep 30, 2024
@rodja
Copy link
Member

rodja commented Oct 1, 2024

That it strange. Can anyone else reproduce this error? On Mac the dev container seems to run the tests without any cpu spikes:
devcontainer-test

@falkoschindler falkoschindler added the help wanted Extra attention is needed label Oct 1, 2024
@valankar
Copy link
Author

valankar commented Oct 1, 2024

FWIW I'm running Windows 11. I tried both using a WSL2 remote container on local Debian (WSL), as well as a remote SSH on a Debian server. Both result in chromium using 100% cpu and timing out the test. Are you using Debian for the container or something else? I can't tell from the screenshot. Also your process listing shows chrome, whereas mine shows chromium. Not sure if that is relevant.

@valankar
Copy link
Author

valankar commented Oct 1, 2024

I just tried with container on Ubuntu-24.04 WSL2. Similarly fails, and also shows chromium vs chrome.

@rodja
Copy link
Member

rodja commented Oct 4, 2024

Are you using Debian for the container or something else?

I have started our devcontainer specified in https://github.com/zauberzeug/nicegui/blob/main/.devcontainer/devcontainer.json which is Debian based. Are you not using this configuration?

@valankar
Copy link
Author

valankar commented Oct 4, 2024

Yes. I'm referring to the docker host, i.e. the host that creates and runs the devcontainer. At least on Windows, there are a couple of possibilities:

  1. Docker daemon running on a distribution in WSL2
  2. Docker daemon running on a remote machine via SSH
  3. Docker daemon running on Docker Desktop with WSL2
  4. Docker daemon running on Docker Desktop with Hyper-V

Some of these can be a specific Linux distribution. But it really should not matter, I'm just curious. It sounds like on Mac it is just the docker daemon on Mac.

Is there any Windows developer of NiceGUI that can confirm it works (i.e. not a Mac user)?

I will try to create a video showing the issue.

@valankar
Copy link
Author

valankar commented Oct 4, 2024

Here is a video showing what I did:

https://youtu.be/rG2LzK5Qf1A?si=YDSZs8ftGLT4kd_C

In this one I'm just using Docker Desktop with WSL2. I cancelled the tests after 10 minutes. The chromium process stays running at 100% cpu and needs to be killed.

@GrazingScientist
Copy link
Contributor

I am currently on a Mac using colima and emulating an AMD64 architecture and encountering the same issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants