{"action":"created","issue":{"url":"https://api.github.com/repos/facebook/react-native/issues/9541","repository_url":"https://api.github.com/repos/facebook/react-native","labels_url":"https://api.github.com/repos/facebook/react-native/issues/9541/labels{/name}","comments_url":"https://api.github.com/repos/facebook/react-native/issues/9541/comments","events_url":"https://api.github.com/repos/facebook/react-native/issues/9541/events","html_url":"https://github.com/facebook/react-native/pull/9541","id":172662172,"number":9541,"title":"Copy class list on every reload to support dynamic context in DEBUG-mode","user":{"login":"kasper","id":925851,"avatar_url":"https://avatars.githubusercontent.com/u/925851?v=3","gravatar_id":"","url":"https://api.github.com/users/kasper","html_url":"https://github.com/kasper","followers_url":"https://api.github.com/users/kasper/followers","following_url":"https://api.github.com/users/kasper/following{/other_user}","gists_url":"https://api.github.com/users/kasper/gists{/gist_id}","starred_url":"https://api.github.com/users/kasper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kasper/subscriptions","organizations_url":"https://api.github.com/users/kasper/orgs","repos_url":"https://api.github.com/users/kasper/repos","events_url":"https://api.github.com/users/kasper/events{/privacy}","received_events_url":"https://api.github.com/users/kasper/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/facebook/react-native/labels/CLA%20Signed","name":"CLA Signed","color":"e7e7e7"},{"url":"https://api.github.com/repos/facebook/react-native/labels/GH%20Review:%20review-needed","name":"GH Review: review-needed","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-08-23T10:17:15Z","updated_at":"2016-08-23T10:22:22Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/facebook/react-native/pulls/9541","html_url":"https://github.com/facebook/react-native/pull/9541","diff_url":"https://github.com/facebook/react-native/pull/9541.diff","patch_url":"https://github.com/facebook/react-native/pull/9541.patch"},"body":"**Motivation:** We have a project that dynamically changes classes in runtime. This component is initialised within the React Native context. Therefor `RCTBatchedBridge` copies the classes before changes are made to them. While React Native is running, changes are made to the classes dynamically. When the project reloads the `RCTBatchedBridge`, it now has an invalid list of classes containing trash pointers. This causes the project to crash on https://github.com/facebook/react-native/blob/master/React/Base/RCTBatchedBridge.m#L288 with EXC_BAD_ACCESS in the DEBUG-mode.\r\n\r\n**Solution:** Copy the class list on each reload to get the current state. Since this is only a DEBUG-feature the overhead of this should not be a major issue."},"comment":{"url":"https://api.github.com/repos/facebook/react-native/issues/comments/241689450","html_url":"https://github.com/facebook/react-native/pull/9541#issuecomment-241689450","issue_url":"https://api.github.com/repos/facebook/react-native/issues/9541","id":241689450,"user":{"login":"facebook-github-bot-7","id":8397364,"avatar_url":"https://avatars.githubusercontent.com/u/8397364?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook-github-bot-7","html_url":"https://github.com/facebook-github-bot-7","followers_url":"https://api.github.com/users/facebook-github-bot-7/followers","following_url":"https://api.github.com/users/facebook-github-bot-7/following{/other_user}","gists_url":"https://api.github.com/users/facebook-github-bot-7/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook-github-bot-7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook-github-bot-7/subscriptions","organizations_url":"https://api.github.com/users/facebook-github-bot-7/orgs","repos_url":"https://api.github.com/users/facebook-github-bot-7/repos","events_url":"https://api.github.com/users/facebook-github-bot-7/events{/privacy}","received_events_url":"https://api.github.com/users/facebook-github-bot-7/received_events","type":"User","site_admin":false},"created_at":"2016-08-23T10:22:22Z","updated_at":"2016-08-23T10:22:22Z","body":"Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks!"}}
{"actor":{"display_login":"facebook-github-bot-7"}}