-
Notifications
You must be signed in to change notification settings - Fork 47.1k
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
Error: "Cannot remove node "2626" because no matching node was found in the Store." #21442
Comments
Hi @neerajverma101! I'm sorry you ran into this problem 😦 Unfortunately, it doesn't look like this issue has enough info for one of us to reproduce it though. This means that it's going to be very hard for us to fix. Please help us by providing a link to a CodeSandbox (https://codesandbox.io/s/new), a repository on GitHub, or a minimal code example that reproduces the problem. (Screenshots or videos can also be helpful if they help provide context on how to repro the bug.) Here are some tips for providing a minimal example: https://stackoverflow.com/help/mcve |
FWIW I just got this error and clicked on the link in dev tools to this issue. HMR got a 500 loading the new module from Vite, then renders failed. This happened when i saved a file I was editing with invalid syntax so it couldn't be transformed. |
Funnily, i also run into this issue. I am running vite, just like @JakeGinnivan |
I wonder if it has something to do with Fast Refresh's restore mechanism where it remounts previously failed roots. Maybe those don't get registered somehow? |
DevTools + Fast Refresh related bug: #21436 (comment) I'm working on an integration test this morning for stuff like this. Edit I found at least one failing test: #21436 (comment) |
Hello, quick fix for users here: on firefox I've rollbacked to version 4.13.0. Add the extension and enjoy debugging again ! |
@Ostefanini @neerajverma101 @mastorm @JakeGinnivan A repro for this bug would be hugely helpful. So far we've gotten reports but no steps to reproduce it (so we can fix it). Temporarily rolling back the extension is fine to work around the immediate problem but it's not a long term solution 😄 A code example that reproduces the problem (maybe a GitHub repo we could check out and run) would enable us to find and fix the bug and release a patch update. |
Also getting this error on a project I've been working on for two months without issue. I'd like to offer up the repo but it's private with sensitive info. If there's anything I can do to help that isn't divulging the repo then I'm happy to do so. Sorry I can't be of more help, but this is very much a problem for me so keen to help where I can. Thanks. |
Unfortunately we really just need a repro. The stack trace is going ot be the same, so screenshots of the error don't give us any additional information. :) Thanks though. |
I'll see if I can duplicate the repo and trim the fat then comment back! |
That would be super helpful |
I'm sorry, tried and failed (sort of). Too much of the project depends upon connections that must remain private. FWIW, trying to trim the fat somehow solved the problem. I removed some connections to a Parse server hosted on back4app, and also removed a google maps JS API. Specifically, I get this problem with material UI dialog onClose after opening a dialog on a @react-google-maps/api map. Oddly, it also occurs when navigating away from one of my navbar pages which requires a connection to said B4A server but not other pages that don't. Sorry I can't be of more help. |
I also run into this issue, working with react. Its not my repo to share.. so unfortunately I cant. But I got very strange behavior with the state, trying to update after fetching data from the server, it does not reach the state, most of the times... it does when I update the code on VSC on the first render after the save, but then when I refresh the page the data disappears from the state. I added a button, saving mock data in the state ({name: me}), got an additional layer of strangeness. |
I think #21506 might be one way to fix this issue. |
@pauldewilson Would you be interested in trying a build of DevTools (that I can attach to this issue) to see if I've fixed the problem with some changes I've made locally? |
Hi @bvaughn yes very happy to try that. Thank you! |
@pauldewilson Thank you! Here's a build that fixes the problem for me (in unit tests and my local repro). |
|
Thanks for trying it, @pauldewilson. I'm curious, what happens if you dismiss the error dialog? I guess at this point, I'd really like to get my hands on a repro from you. I could sign an NDA or something if that would be helpful? |
Works around the corrupted Store state by detecting a broken Fast Refresh remount and forcefully dropping the root and re-mounting the entire tree. This prevents Fibers from getting duplicated in the Store (and in the Components tree). The benefit of this approach is that it doesn't rely on an update or change in behavior to Fast Refresh. (This workaround is pretty dirty, but since it's a DEV-only code path, it's probably okay.) Note that this change doesn't fix all of the reported issues (see #21442 (comment)) but it does fix some of them. This commit also slightly refactors the way DevTools assigns and manages unique IDs for Fibers in the backend by removing the indirection of a "primary Fiber" and instead mapping both the primary and alternate. It also removes the previous cache-on-read behavior of getFiberID and splits the method into three separate functions for different use cases: * getOrGenerateFiberID – Like the previous function, this method returns an ID or generates and caches a new one if the Fiber hasn't been seen before. * getFiberIDUnsafe – This function returns an ID if one has already been generated or null if not. (It can be used to e.g. log a message about a Fiber without potentially causing it to leak.) * getFiberIDThrows – This function returns an ID if one has already been generated or it throws. (It can be used to guarantee expected behavior rather than to silently cause a leak.)
This issue is now blocked by not having a repro. #21516 should improve the situation but apparently not fix it entirely. That being said, I'm not sure how to proceed until I get a repro from someone, so I'm tagging all of the folks above who have commented that they're seeing this in hopes that one of them can share something with me. |
@pauldewilson Can you try this build? 😬 |
Seems to have fixed it! Thank you! And no NDA required after all! |
Thanks for confirming |
Should be fixed by #21523. If you'd like to verify, download this build: And follow these steps to install it: |
…#21516) Works around the corrupted Store state by detecting a broken Fast Refresh remount and forcefully dropping the root and re-mounting the entire tree. This prevents Fibers from getting duplicated in the Store (and in the Components tree). The benefit of this approach is that it doesn't rely on an update or change in behavior to Fast Refresh. (This workaround is pretty dirty, but since it's a DEV-only code path, it's probably okay.) Note that this change doesn't fix all of the reported issues (see facebook#21442 (comment)) but it does fix some of them. This commit also slightly refactors the way DevTools assigns and manages unique IDs for Fibers in the backend by removing the indirection of a "primary Fiber" and instead mapping both the primary and alternate. It also removes the previous cache-on-read behavior of getFiberID and splits the method into three separate functions for different use cases: * getOrGenerateFiberID – Like the previous function, this method returns an ID or generates and caches a new one if the Fiber hasn't been seen before. * getFiberIDUnsafe – This function returns an ID if one has already been generated or null if not. (It can be used to e.g. log a message about a Fiber without potentially causing it to leak.) * getFiberIDThrows – This function returns an ID if one has already been generated or it throws. (It can be used to guarantee expected behavior rather than to silently cause a leak.)
I still have this error, on CodeSandbox, when I switch routes. https://codesandbox.io/s/react-router-remote-table-demo-ojn3wp?file=/src/hooks.ts But it works when I open the app in a separate window. |
Which website or app were you using when the bug happened?
Please provide a link to the URL of the website (if it is public), a CodeSandbox (https://codesandbox.io/s/new) example that reproduces the bug, or a project on GitHub that we can checkout and run locally.
What were you doing on the website or app when the bug happened?
If possible, please describe how to reproduce this bug on the website or app mentioned above:
Generated information
DevTools version: 4.13.1-93782cfed2
Call stack:
at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:21499:43
at bridge_Bridge.emit (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:19607:22)
at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:19767:12
at listener (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:37788:39)
Component stack:
(none)
GitHub URL search query:
https://api.github.com/search/issues?q=Cannot%20remove%20node%20%20because%20no%20matching%20node%20was%20found%20in%20the%20Store.%20in%3Atitle%20is%3Aissue%20is%3Aopen%20is%3Apublic%20label%3A%22Component%3A%20Developer%20Tools%22%20repo%3Afacebook%2Freact
The text was updated successfully, but these errors were encountered: