{"action":"created","issue":{"url":"https://api.github.com/repos/jquense/react-widgets/issues/54","labels_url":"https://api.github.com/repos/jquense/react-widgets/issues/54/labels{/name}","comments_url":"https://api.github.com/repos/jquense/react-widgets/issues/54/comments","events_url":"https://api.github.com/repos/jquense/react-widgets/issues/54/events","html_url":"https://github.com/jquense/react-widgets/issues/54","id":59469760,"number":54,"title":"DatePicker Animation crashing when component is unmounted","user":{"login":"vladimir-rovensky","id":10760126,"avatar_url":"https://avatars.githubusercontent.com/u/10760126?v=3","gravatar_id":"","url":"https://api.github.com/users/vladimir-rovensky","html_url":"https://github.com/vladimir-rovensky","followers_url":"https://api.github.com/users/vladimir-rovensky/followers","following_url":"https://api.github.com/users/vladimir-rovensky/following{/other_user}","gists_url":"https://api.github.com/users/vladimir-rovensky/gists{/gist_id}","starred_url":"https://api.github.com/users/vladimir-rovensky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vladimir-rovensky/subscriptions","organizations_url":"https://api.github.com/users/vladimir-rovensky/orgs","repos_url":"https://api.github.com/users/vladimir-rovensky/repos","events_url":"https://api.github.com/users/vladimir-rovensky/events{/privacy}","received_events_url":"https://api.github.com/users/vladimir-rovensky/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-03-02T11:33:39Z","updated_at":"2015-03-02T17:29:52Z","closed_at":"2015-03-02T15:59:53Z","body":"Hey again\r\n\r\nI'm having a weird problem with the DatePicker that I can't quite pinpoint. Some of my unit tests keep failing with the React invariant violation: getDOMNode(): A component must be mounted to have a DOM node. \r\nI tried to debug this as far as I could and it happens in ReplaceTransitionGroup's _tryFinish method, which tries to acquire the DOM node of an element that is unmounted. In general, I think the problem is that the animation can finish after the component has been unmounted, resulting in this error.\r\n\r\nDo you think I'm doing something wrong? If not, would it be possible for the ReplaceTransitonGroup to check for the unmounted state prior to whatever it is trying to do with the DOM node?\r\n\r\nAs a side note, it seems like the DateTimePicker does not pass its duration property to the underlying Calendar component, which might be related to the issue I'm having (we always use 0 durations for animations), but it might not be the only problem.\r\n\r\nAny help/suggestions would be most welcome.\r\n"},"comment":{"url":"https://api.github.com/repos/jquense/react-widgets/issues/comments/76757368","html_url":"https://github.com/jquense/react-widgets/issues/54#issuecomment-76757368","issue_url":"https://api.github.com/repos/jquense/react-widgets/issues/54","id":76757368,"user":{"login":"vladimir-rovensky","id":10760126,"avatar_url":"https://avatars.githubusercontent.com/u/10760126?v=3","gravatar_id":"","url":"https://api.github.com/users/vladimir-rovensky","html_url":"https://github.com/vladimir-rovensky","followers_url":"https://api.github.com/users/vladimir-rovensky/followers","following_url":"https://api.github.com/users/vladimir-rovensky/following{/other_user}","gists_url":"https://api.github.com/users/vladimir-rovensky/gists{/gist_id}","starred_url":"https://api.github.com/users/vladimir-rovensky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vladimir-rovensky/subscriptions","organizations_url":"https://api.github.com/users/vladimir-rovensky/orgs","repos_url":"https://api.github.com/users/vladimir-rovensky/repos","events_url":"https://api.github.com/users/vladimir-rovensky/events{/privacy}","received_events_url":"https://api.github.com/users/vladimir-rovensky/received_events","type":"User","site_admin":false},"created_at":"2015-03-02T17:29:52Z","updated_at":"2015-03-02T17:29:52Z","body":"Hey there\r\n\r\nWe're definitely on the right track here, but there's still an error, even if I apply your fix locally. This time it happens in _handleDoneLeaving (again in ReplaceTransitionGroup), which tries to setState after the component has unmounted. Could we add one more check in _handleDoneLeaving?\r\n\r\nMany thanks for your work on this project BTW, I appreciate the effort you're putting into this."}}