{"action":"created","issue":{"url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/884","repository_url":"https://api.github.com/repos/Automattic/simplenote-electron","labels_url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/884/labels{/name}","comments_url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/884/comments","events_url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/884/events","html_url":"https://github.com/Automattic/simplenote-electron/pull/884","id":364088238,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE4MzYwMTky","number":884,"title":"Keep selected note in React in sync with Redux state","user":{"login":"mirka","id":555336,"node_id":"MDQ6VXNlcjU1NTMzNg==","avatar_url":"https://avatars3.githubusercontent.com/u/555336?v=4","gravatar_id":"","url":"https://api.github.com/users/mirka","html_url":"https://github.com/mirka","followers_url":"https://api.github.com/users/mirka/followers","following_url":"https://api.github.com/users/mirka/following{/other_user}","gists_url":"https://api.github.com/users/mirka/gists{/gist_id}","starred_url":"https://api.github.com/users/mirka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirka/subscriptions","organizations_url":"https://api.github.com/users/mirka/orgs","repos_url":"https://api.github.com/users/mirka/repos","events_url":"https://api.github.com/users/mirka/events{/privacy}","received_events_url":"https://api.github.com/users/mirka/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/Automattic/simplenote-electron/milestones/10","html_url":"https://github.com/Automattic/simplenote-electron/milestone/10","labels_url":"https://api.github.com/repos/Automattic/simplenote-electron/milestones/10/labels","id":3728175,"node_id":"MDk6TWlsZXN0b25lMzcyODE3NQ==","number":10,"title":"1.2.1","description":null,"creator":{"login":"mirka","id":555336,"node_id":"MDQ6VXNlcjU1NTMzNg==","avatar_url":"https://avatars3.githubusercontent.com/u/555336?v=4","gravatar_id":"","url":"https://api.github.com/users/mirka","html_url":"https://github.com/mirka","followers_url":"https://api.github.com/users/mirka/followers","following_url":"https://api.github.com/users/mirka/following{/other_user}","gists_url":"https://api.github.com/users/mirka/gists{/gist_id}","starred_url":"https://api.github.com/users/mirka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirka/subscriptions","organizations_url":"https://api.github.com/users/mirka/orgs","repos_url":"https://api.github.com/users/mirka/repos","events_url":"https://api.github.com/users/mirka/events{/privacy}","received_events_url":"https://api.github.com/users/mirka/received_events","type":"User","site_admin":false},"open_issues":4,"closed_issues":0,"state":"open","created_at":"2018-10-10T16:45:12Z","updated_at":"2018-10-10T16:49:06Z","due_on":null,"closed_at":null},"comments":1,"created_at":"2018-09-26T15:26:46Z","updated_at":"2018-10-10T17:18:52Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/Automattic/simplenote-electron/pulls/884","html_url":"https://github.com/Automattic/simplenote-electron/pull/884","diff_url":"https://github.com/Automattic/simplenote-electron/pull/884.diff","patch_url":"https://github.com/Automattic/simplenote-electron/pull/884.patch"},"body":"Closes #838 \r\n\r\n## Problem\r\n\r\nThe Redux `appState.note` could be out of sync with the actual displayed note in React. This was causing crashes because some parts of the app (e.g. ShareDialog) were relying on `appState.note` to determine state, while other parts (e.g. NoteDetail) were using a `selectedNote` computed independently by app.jsx.\r\n\r\n## Fix\r\n\r\nIn this fix, app.jsx will no longer attempt to compute its own \"selected note\", and will always rely on the Redux `appState.note`. This should prevent the kind of bugs/crashes that are caused by the two being out of sync.\r\n\r\nThere are non-trivial changes to the state-handling logic, so this should be tested thoroughly before release."},"comment":{"url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/comments/428656673","html_url":"https://github.com/Automattic/simplenote-electron/pull/884#issuecomment-428656673","issue_url":"https://api.github.com/repos/Automattic/simplenote-electron/issues/884","id":428656673,"node_id":"MDEyOklzc3VlQ29tbWVudDQyODY1NjY3Mw==","user":{"login":"roundhill","id":789137,"node_id":"MDQ6VXNlcjc4OTEzNw==","avatar_url":"https://avatars3.githubusercontent.com/u/789137?v=4","gravatar_id":"","url":"https://api.github.com/users/roundhill","html_url":"https://github.com/roundhill","followers_url":"https://api.github.com/users/roundhill/followers","following_url":"https://api.github.com/users/roundhill/following{/other_user}","gists_url":"https://api.github.com/users/roundhill/gists{/gist_id}","starred_url":"https://api.github.com/users/roundhill/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/roundhill/subscriptions","organizations_url":"https://api.github.com/users/roundhill/orgs","repos_url":"https://api.github.com/users/roundhill/repos","events_url":"https://api.github.com/users/roundhill/events{/privacy}","received_events_url":"https://api.github.com/users/roundhill/received_events","type":"User","site_admin":false},"created_at":"2018-10-10T17:18:52Z","updated_at":"2018-10-10T17:18:52Z","author_association":"MEMBER","body":"> @roundhill Oh yes I forgot to mention, I've opted to deal with the `selectedNoteId` redundancy as a separate issue (#883), if that's ok. It's being used in several places, and I was afraid there might be ramifications that are not immediately apparent 😬\r\n\r\nAh, ok. :shipit: then!"}}
{"actor":{"display_login":"roundhill"}}