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

Cannot read property 'getHostNode' of null #8579

Closed
kevart opened this Issue Dec 15, 2016 · 8 comments

Comments

Projects
None yet
6 participants
@kevart

kevart commented Dec 15, 2016

feature request

What is the current behavior?
Cannot read property 'getHostNode' of null

What is the expected behavior?
An error message that tells me what is wrong so I know what to fix.

"react": "15.3.2"

@gaearon

This comment has been minimized.

Show comment
Hide comment
@gaearon

gaearon Dec 15, 2016

Member

Please see #8267.
This usually means React is an inconsistent state caused by an earlier error in your code.
If you don't see this error it might be because you have a catch block silently swallowing it.

Related explanations: #7617 (comment), #4199 (comment).

If you’re sure this is not the problem please provide a reproducing example.

Member

gaearon commented Dec 15, 2016

Please see #8267.
This usually means React is an inconsistent state caused by an earlier error in your code.
If you don't see this error it might be because you have a catch block silently swallowing it.

Related explanations: #7617 (comment), #4199 (comment).

If you’re sure this is not the problem please provide a reproducing example.

@aweary

This comment has been minimized.

Show comment
Hide comment
@aweary

aweary Dec 20, 2016

Member

Closing as there's been no update and it's likely related to #8267. @kevart if provide a case reproducing the issue we can look into re-opening it if its identified as a different issue.

Member

aweary commented Dec 20, 2016

Closing as there's been no update and it's likely related to #8267. @kevart if provide a case reproducing the issue we can look into re-opening it if its identified as a different issue.

@aweary aweary closed this Dec 20, 2016

@AjayU

This comment has been minimized.

Show comment
Hide comment
@AjayU

AjayU May 31, 2017

Getting this error in IE. The build application works fine in mozilla and chrome. Moreover, the standalone express server app runs fine too in IE but the built js file using webpack and babel fails to navigate when used inside of a jsp file

AjayU commented May 31, 2017

Getting this error in IE. The build application works fine in mozilla and chrome. Moreover, the standalone express server app runs fine too in IE but the built js file using webpack and babel fails to navigate when used inside of a jsp file

@bhgames

This comment has been minimized.

Show comment
Hide comment
@bhgames

bhgames commented Jun 6, 2017

Same here @AjayU

@bhgames

This comment has been minimized.

Show comment
Hide comment
@bhgames

bhgames Jun 7, 2017

@AjayU I discovered it was because I was using for(let key of something) { } loops in my code. Apparently this isn't polyfilled properly. Replacing them with .map({})'s worked. Had nothing to do with react-router - it was just that was firing the render call that caused the error to happen.

bhgames commented Jun 7, 2017

@AjayU I discovered it was because I was using for(let key of something) { } loops in my code. Apparently this isn't polyfilled properly. Replacing them with .map({})'s worked. Had nothing to do with react-router - it was just that was firing the render call that caused the error to happen.

@vTrip

This comment has been minimized.

Show comment
Hide comment
@vTrip

vTrip Jun 19, 2017

this issue occurs for me specifically when using setState

vTrip commented Jun 19, 2017

this issue occurs for me specifically when using setState

@facebook facebook locked and limited conversation to collaborators Jun 19, 2017

@gaearon

This comment has been minimized.

Show comment
Hide comment
@gaearon

gaearon Jun 19, 2017

Member

Please read this comment: #8579 (comment).
When you see this issue without a descriptive error before it, your code is swallowing errors.

I'm locking the issue because further comments will just confuse people googling it. The cause of this error is always another error that happened earlier (but that your code might have swallowed it).

Member

gaearon commented Jun 19, 2017

Please read this comment: #8579 (comment).
When you see this issue without a descriptive error before it, your code is swallowing errors.

I'm locking the issue because further comments will just confuse people googling it. The cause of this error is always another error that happened earlier (but that your code might have swallowed it).

@gaearon

This comment has been minimized.

Show comment
Hide comment
@gaearon

gaearon Jul 27, 2017

Member

A small update on this. We just released React 16 beta which shouldn’t emit cryptic errors like this one. Even if the application code swallows an error, React 16 will still print it to the console. It might be too early for you to try React 16 (since ecosystem is still preparing for it), but this error should never occur in the future after you switch to it.

Member

gaearon commented Jul 27, 2017

A small update on this. We just released React 16 beta which shouldn’t emit cryptic errors like this one. Even if the application code swallows an error, React 16 will still print it to the console. It might be too early for you to try React 16 (since ecosystem is still preparing for it), but this error should never occur in the future after you switch to it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.