react icon indicating copy to clipboard operation
react copied to clipboard

[DevTools Bug]: Excessive CPU Usage

Open jscheel opened this issue 2 years ago • 5 comments

Website or app

Happens even after all tabs are closed

Repro steps

I don't have clear repro steps yet. Occasionally I will notice that Chrome is using 170%-200% CPU. I close all my tabs, and it continues. Then I open the extensions management page and disable react devtools. This immediately fixes the problem. Re-enabling the extension does not re-engage the high cpu issue.

How often does this bug happen?

Sometimes

DevTools package (automated)

No response

DevTools version (automated)

No response

Error message (automated)

No response

Error call stack (automated)

No response

Error component stack (automated)

No response

GitHub query string (automated)

No response

jscheel avatar Dec 04 '23 21:12 jscheel

This is interesting, thanks for reporting. If you are saying that disabling React DevTools immediately fixes the problem, then the issue is somewhere in the service worker, potentially a deadlock.

I would really appreciate if you can provide any reproducing example, or you if you can validate on a small sample of tabs that closing all of them doesn't free CPU, unless React DevTools extension is disabled.

hoxyq avatar Dec 04 '23 21:12 hoxyq

@hoxyq I'll keep an eye on it. I spend most of my day on our app at groovehq.com, but in the local development version. It's possible that something is happening there. Hard to pinpoint, but I'll give it a try!

jscheel avatar Dec 05 '23 22:12 jscheel

i had the same issue. it went away when i disabled react tools on all wesites except localhost:4000. it appears that react tools add-on on other websites was causing this issue. it could be concurrency related, or a bug that crashed the tool on non-, react sites.

panfiva avatar Dec 19 '23 14:12 panfiva

Just wanted to chime back in here. This is still happening, but I cannot pin it down to a specific set of tabs.

jscheel avatar Feb 21 '24 16:02 jscheel