-
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
Error: "Commit tree does not contain fiber 256. This is a bug in React DevTools." #18831
Comments
Are you able to repro this? If so, can you share a repro case with us? |
@bvaughn Setup: Run app:
When its done gathering the results it errors out. Stacktrace i got:
Sorry was not able to get a more isolated test case, just came across it Also was not able to reliably reproduce, feels like its related to garbage collection |
@adaschevici Thanks for sharing repro instructions!
Any chance you could just deploy this app somewhere I could look at it already running? |
@bvaughn the error you are seeing is most likely caused by the fact that the git module for the jungle-jim is not automatically cloned. |
Ah, I think my |
That being said, once the app started, I see another error (in the browser this time):
Again, any chance you could just deploy this app somewhere I could look at it already running? 😅 |
ugh. Yeah, not sure if i can deploy it it needs the mocked API and some extra config i'm not able to do fast enough. |
No problem. Keep me posted! I'm happy to try something else on the local checkout if you have additional suggestions for resolving the latest compilation error too. Getting a repro of this would be very helpful. |
oh, right so you also need to run |
Cool. Thanks @adaschevici. I can run the app locally now. How frequently can you reproduce it? Every other time? One in ten times? (I haven't seen it yet so I'm just wondering if I'm doing something wrong.) Also, when you see it- is it immediately after stopping profiling? Or do you click around or do anything else? |
I haven't seen it since the first time i tried profiling the app. After that i did a hard refresh with clearing cache in chrome and have not seen it since. What i did when i did see it:
Actual: the error previously mentioned |
I was unable to reproduce it since I posted the issue. |
This sounds...unexpected. Makes me think something else was going on. Especially for such a small app, stop profiling should seem to be nearly instant. |
Reproduction of the issue:
Reproduction steps:
Any requirement for extra information are welcome! |
@loia5tqd001 Thank you for the repro! Can confirm it repros on my end. This is a huge help! I'll dig in this morning. |
I think I've paired the repro down to this Code Sandbox |
Unfortunately this looks like another recent regression 😦 because this bug doesn't manifest in v4.7 Still good to have a repro for, and I'm investigating a fix today. I don't think it will fix the longer standing (much less harder to find a repro for) issue. |
FYI I've reduced the failure case to the following test: it('should not crash during route transitions with Suspense', () => {
const RouterContext = React.createContext();
function App() {
return (
<Router>
<Switch>
<Route path="/"><Home /></Route>
<Route path="/about"><About /></Route>
</Switch>
</Router>
);
}
const Home = () => {
return (
<React.Suspense>
<Link path="/about">Home</Link>
</React.Suspense>
);
};
const About = () => <div>About</div>;
// Mimics https://github.com/ReactTraining/react-router/blob/master/packages/react-router/modules/Router.js
function Router({children}) {
const [path, setPath] = React.useState('/');
return (
<RouterContext.Provider value={{ path, setPath }}>
{children}
</RouterContext.Provider>
);
}
// Mimics https://github.com/ReactTraining/react-router/blob/master/packages/react-router/modules/Switch.js
function Switch({ children }) {
return (
<RouterContext.Consumer>
{context => {
let element = null;
React.Children.forEach(children, child => {
if (context.path === child.props.path) {
element = child.props.children;
}
});
return element
? React.cloneElement(element)
: null;
}}
</RouterContext.Consumer>
);
}
// Mimics https://github.com/ReactTraining/react-router/blob/master/packages/react-router/modules/Route.js
function Route({ children, path }) {
return null;
}
const linkRef = React.createRef();
// Mimics https://github.com/ReactTraining/react-router/blob/master/packages/react-router-dom/modules/Link.js
function Link({ children, path }) {
return (
<RouterContext.Consumer>
{context => {
return (
<button ref={linkRef} onClick={() => context.setPath(path)}>{children}</button>
);
}}
</RouterContext.Consumer>
);
}
const container = document.createElement('div');
utils.act(() => ReactDOM.render(<App />, container));
expect(container.textContent).toBe('Home');
utils.act(() => Simulate.click(linkRef.current));
expect(container.textContent).toBe('About');
}); The error being thrown is when the |
Version 4.8.2 has just been published to NPM and submitted to Chrome/Edge/Firefox stores with a fix for this issue. Browsers sometimes take a few hours to approve a new extension version, but once the new version goes live this should be resolved. Sorry for the inconvenience. |
@bvaughn |
Describe what you were doing when the bug occurred:
In a component that rendered 5000 pre tags with single lines of text in them, that has an unrelated controlled text box is the same component that was typed into while profiling. App hung a while and, when it rendered again the error was in the profiler.
Please do not remove the text below this line
DevTools version: 4.6.0-6cceaeb67
Call stack: at j (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:162825)
at N (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:161628)
at e.getCommitTree (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:164582)
at ec (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:339280)
at ci (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:59620)
at Ll (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:109960)
at qc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:102381)
at Hc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:102306)
at Vc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:102171)
at Tc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:98781)
Component stack: in ec
in div
in div
in div
in So
in Unknown
in n
in Unknown
in div
in div
in rl
in Ze
in fn
in Ga
in _s
The text was updated successfully, but these errors were encountered: