{"action":"created","issue":{"url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/111","repository_url":"https://api.github.com/repos/webpack/webpack-dev-server","labels_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/111/labels{/name}","comments_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/111/comments","events_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/111/events","html_url":"https://github.com/webpack/webpack-dev-server/issues/111","id":57916724,"number":111,"title":"Getting `Uncaught NotFoundError` when hitting `React.render` after fetching external resource","user":{"login":"bebraw","id":166921,"avatar_url":"https://avatars.githubusercontent.com/u/166921?v=3","gravatar_id":"","url":"https://api.github.com/users/bebraw","html_url":"https://github.com/bebraw","followers_url":"https://api.github.com/users/bebraw/followers","following_url":"https://api.github.com/users/bebraw/following{/other_user}","gists_url":"https://api.github.com/users/bebraw/gists{/gist_id}","starred_url":"https://api.github.com/users/bebraw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bebraw/subscriptions","organizations_url":"https://api.github.com/users/bebraw/orgs","repos_url":"https://api.github.com/users/bebraw/repos","events_url":"https://api.github.com/users/bebraw/events{/privacy}","received_events_url":"https://api.github.com/users/bebraw/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/webpack/webpack-dev-server/labels/Needs%20Response%20From%20Author","name":"Needs Response From Author","color":"eb6420"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2015-02-17T12:10:33Z","updated_at":"2016-08-25T08:52:45Z","closed_at":"2016-08-25T08:52:45Z","body":"I have a setup like this (simplified but still reproducible):\r\n\r\n**index.js**\r\n\r\n```javascript\r\nvar React = require('react');\r\nvar Router = require('react-router');\r\n\r\nvar routes = require('./routes.jsx');\r\n\r\n\r\nroutes().then(function(routeDefinition) {\r\n    React.render(<div>hello</div>, document.body);\r\n}).catch(function(res) {\r\n    console.error(res);\r\n});\r\n```\r\n\r\n**routes.jsx**\r\n\r\n```jsx\r\n'use strict';\r\n\r\nvar React = require('react');\r\nvar Promise = require('es6-promise').Promise;\r\n\r\nvar url = 'http://localhost:3000'; // TODO: move this to configuration\r\nvar api = require('./api');\r\n\r\n\r\nmodule.exports = function() {\r\n    return new Promise(function(resolve, reject) {\r\n        api(url).then(function(api) {\r\n            resolve();\r\n        }).catch(function(res) {\r\n            reject(res);\r\n        });\r\n    });\r\n};\r\n```\r\n\r\n***api.js**\r\n\r\n```javascript\r\nvar Promise = require('es6-promise').Promise;\r\nvar axios = require('axios');\r\n\r\n\r\nmodule.exports = function(url) {\r\n    return new Promise(function(resolve, reject) {\r\n        axios.get(url + '/v1/schema').then(function() {\r\n            resolve();\r\n        }).catch(function(res) {\r\n            reject(res);\r\n        });\r\n    });\r\n};\r\n```\r\n\r\nAs you can see I hit an external API before I render anything. The full code constructs an API based on an external resource but it seems it is possible to trigger the glitch only by doing that call to an external API.\r\n\r\nA setup like this yields `socket.io.js:2695 Uncaught NotFoundError: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.`.\r\n\r\nIf I get rid of the call to an external API, the error goes away. Any idea what might be causing the problem? Could it have to do something with the fact that both resources are at `localhost`? How could that mess up `socket.io`? Is there a way to run the dev server that gives more debug info?\r\n\r\nIf you want to see the issue in action, check out [koodilehto-crm-frontend](https://github.com/koodilehto/koodilehto-crm-frontend/tree/v0.1.0). You'll also need [a backend](https://github.com/koodilehto/koodilehto-crm-backend) to run against."},"comment":{"url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/comments/242321069","html_url":"https://github.com/webpack/webpack-dev-server/issues/111#issuecomment-242321069","issue_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/111","id":242321069,"user":{"login":"bebraw","id":166921,"avatar_url":"https://avatars.githubusercontent.com/u/166921?v=3","gravatar_id":"","url":"https://api.github.com/users/bebraw","html_url":"https://github.com/bebraw","followers_url":"https://api.github.com/users/bebraw/followers","following_url":"https://api.github.com/users/bebraw/following{/other_user}","gists_url":"https://api.github.com/users/bebraw/gists{/gist_id}","starred_url":"https://api.github.com/users/bebraw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bebraw/subscriptions","organizations_url":"https://api.github.com/users/bebraw/orgs","repos_url":"https://api.github.com/users/bebraw/repos","events_url":"https://api.github.com/users/bebraw/events{/privacy}","received_events_url":"https://api.github.com/users/bebraw/received_events","type":"User","site_admin":false},"created_at":"2016-08-25T08:52:45Z","updated_at":"2016-08-25T08:52:45Z","body":"Yeah, it has been too long since I opened this issue. Better close. I'll re-open if this comes around again."}}
{"actor":{"display_login":"bebraw"}}