-
Notifications
You must be signed in to change notification settings - Fork 47.2k
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
[DevTools Bug]: Components Tab does not show up #25806
Comments
Some times this show up too:
|
I'm not able to reproduce this issue. Can you let me know which Chrome and DevTools version you are using? |
Sure! Chrome: Btw, I have already done what to mention but no luck. |
I found a workaround to "force" the dev tools to load. Please see below: dev_tools_issue.mp4 |
@antonisprovidakis That's interesting... It seems to be related to how Chrome launch service worker. I'll look into this and see if I can find a way to reproduce it. |
I cannot click service work link. It does not show a new window : ( |
Still not functional with: Chrome: Version 108.0.5359.124 (Official Build) (x86_64) And for anyone who encountered the same problem, I found a somewhat "stable" workaround:
Now it's the important part:
So what I suspect is that due to unknown reason, the react devtool service worker instanciates twice, which causes all those problems. I hope this can help out finding the issue, cause the problem is REALLY annoying. |
@afterwind-io I followed the instructions, but nothing happened. Then, instead of terminating those pesky service workers, I hit "Inspect", ignored the "disconnected" message and read at console something about "Update on reload" option for service workers... I proceeded to |
## Summary This is to fix some edge cases I recently observed when developing and using the extension: - When you reload the page, there's a chance that a port (most likely the devtools one) is not properly unloaded. In this case, the React DevTools will stop working unless you create a new tab. - For unknown reasons, Chrome sometimes spins up two service worker processes. In this case, an error will be thrown "duplicate ID when registering content script" and sometimes interrupt the execution of the rest of service worker. This is an attempt to make the logic more robust - Automatically shutting down the double pipe if the message fails, and allowing the runtime to rebuild the double pipe. - Log the error message so Chrome believes we've handled it and will not interrupt the execution. This also seems to be helpful in fixing #25806.
## Summary This is to fix some edge cases I recently observed when developing and using the extension: - When you reload the page, there's a chance that a port (most likely the devtools one) is not properly unloaded. In this case, the React DevTools will stop working unless you create a new tab. - For unknown reasons, Chrome sometimes spins up two service worker processes. In this case, an error will be thrown "duplicate ID when registering content script" and sometimes interrupt the execution of the rest of service worker. This is an attempt to make the logic more robust - Automatically shutting down the double pipe if the message fails, and allowing the runtime to rebuild the double pipe. - Log the error message so Chrome believes we've handled it and will not interrupt the execution. This also seems to be helpful in fixing #25806. DiffTrain build for [c12194f](c12194f) [View git log for this commit](https://github.com/facebook/react/commits/c12194f7485f298fadc1e51cfffb93e63d61ad96)
Hi everyone. While I was never able to reproduce the issue you were experiencing, I did patch a few places that might have caused this issue. Does the new version (4.27.2) improve things for you? |
@mondaychen So far so good. |
Website or app
https://beta.reactjs.org/
Repro steps
This happens on https://beta.reactjs.org/ but I first noticed in on a personal project (localhost).
When I open the dev tools, the CPU goes up. At first, the Components tab does not show up. After a loooooong time, it does show up, however when I click on it nothing renders inside.
I don't know if it's the newest Chrome version or the newest extension version that's causing it.
How often does this bug happen?
Every time
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
The text was updated successfully, but these errors were encountered: