8000 Invariant Violation: ReactMount: Two valid but unequal nodes with the same `data-reactid` · Issue #1436 · facebook/react · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Invariant Violation: ReactMount: Two valid but unequal nodes with the same data-reactid #1436

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

Closed
btd opened this issue Apr 22, 2014 · 8 comments

Comments

@btd
Copy link
btd commented Apr 22, 2014

The same happen with 0.10 and master.
I am sorry i could not make reproducible test case.
That is stack trace for master:

invariant invariant.js:52
getID ReactMount.js:79
ReactMount.isRenderedByReact ReactMount.js:533
ReactMount.getFirstReactDOM ReactMount.js:548
handleTopLevelImpl ReactEventTopLevelCallback.js:63
Mixin.perform Transaction.js:159
ReactDefaultBatchingStrategy.batchedUpdates ReactDefaultBatchingStrategy.js:70
batchedUpdates ReactUpdates.js:35
ReactEventTopLevelCallback.createTopLevelCallback ReactEventTopLevelCallback.js:151

And for 0.10

invariant invariant.js:52
getID ReactMount.js:79
ReactMount.isRenderedByReact ReactMount.js:532
ReactMount.getFirstReactDOM ReactMount.js:547
handleTopLevelImpl ReactEventTopLevelCallback.js:64
ReactEventTopLevelCallback.createTopLevelCallback ReactEventTopLevelCallback.js:140

Generaly happen such things:
Main component render first time img, then componentDidMount get data via ajax, and on response it update state, then in render img replaced with another component. In moment later it call react trap for 'load' event on previous img and exception happen.

I appreciate feedback and help with issue. I have public link for debuging, but i could not share it with public, so if someone want to see it in action let me know pls.

@syranide
Copy link
Contributor

Could this be related? #1400

Also, we're all on the advertised IRC-channel if you want more direct communication.

@btd
Copy link
Author
btd commented Apr 25, 2014

@syranide Yes message is the same, but cause looks for me different. When first image unmounted later when 'load' happen it uses previous dom representation with old reactid, which is already used by another node.
Thanks, for idea about irc, i will write today.

@syranide
Copy link
Contributor

While it's hard to tell, it could be that you've run into this bug: #1147

I don't remember the exact cause of the bug, but it's something like if you have Root -> Child, if you issue an update to Root and Root directly issues an update on Child (setProps, setState or forceUpdate). Child then updates, but afterrwards the initial update to Root will propagate as usual causing Child to update again, which causes the DOM to be incorrectly overwritten. Sounds like it could be related or totally not? :)

@btd
Copy link
Author
btd commented Apr 25, 2014

Nope, #1147 rather complex but not my case.

@syranide
Copy link
Contributor

Right, if you stop by IRC I could take a look at the link if it's ok, I don't think there's any way to send private information via github?

@syranide
Copy link
Contributor

@spicyj @zpao So the error was apparently <ul><img /></ul>, so related to #1400 and it seems like we really should update that error message to be more helpful?

@sophiebits
Copy link
Collaborator

Want to submit a PR? Will close this in favor of #1400.

@robinma
Copy link
robinma commented Jan 28, 2016

have a same data-id.you mouse mine another plugin tools copy same dom. example swiper loop param.it will copy same dom in you DOC. 坑

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
0