{"action":"created","issue":{"url":"https://api.github.com/repos/onivim/oni/issues/2321","repository_url":"https://api.github.com/repos/onivim/oni","labels_url":"https://api.github.com/repos/onivim/oni/issues/2321/labels{/name}","comments_url":"https://api.github.com/repos/onivim/oni/issues/2321/comments","events_url":"https://api.github.com/repos/onivim/oni/issues/2321/events","html_url":"https://github.com/onivim/oni/pull/2321","id":332709814,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk1MTI0NzIz","number":2321,"title":"[GrammarLoader] Properly check if key is in cache, #1940 fix","user":{"login":"GeorgeTG","id":6360940,"node_id":"MDQ6VXNlcjYzNjA5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6360940?v=4","gravatar_id":"","url":"https://api.github.com/users/GeorgeTG","html_url":"https://github.com/GeorgeTG","followers_url":"https://api.github.com/users/GeorgeTG/followers","following_url":"https://api.github.com/users/GeorgeTG/following{/other_user}","gists_url":"https://api.github.com/users/GeorgeTG/gists{/gist_id}","starred_url":"https://api.github.com/users/GeorgeTG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GeorgeTG/subscriptions","organizations_url":"https://api.github.com/users/GeorgeTG/orgs","repos_url":"https://api.github.com/users/GeorgeTG/repos","events_url":"https://api.github.com/users/GeorgeTG/events{/privacy}","received_events_url":"https://api.github.com/users/GeorgeTG/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-06-15T09:41:14Z","updated_at":"2018-06-18T06:32:31Z","closed_at":"2018-06-17T21:14:45Z","author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/onivim/oni/pulls/2321","html_url":"https://github.com/onivim/oni/pull/2321","diff_url":"https://github.com/onivim/oni/pull/2321.diff","patch_url":"https://github.com/onivim/oni/pull/2321.patch"},"body":"The current check will invalidate the grammar cache if the previous run returned null.\r\nThis is because the key is in the cache but the value is null.\r\nI think this was not intended since it forces a sync expensive function to be re-run every time `getGrammarForLanguage` is called resulting in really bad performance and making the app unusable.\r\n_For example when scrolling this method is called hundreds of times._\r\n\r\nAlso I cannot think of a situation the grammar is going to be found in the next call if the previous failed.\r\nThis also fixes #1940"},"comment":{"url":"https://api.github.com/repos/onivim/oni/issues/comments/397954826","html_url":"https://github.com/onivim/oni/pull/2321#issuecomment-397954826","issue_url":"https://api.github.com/repos/onivim/oni/issues/2321","id":397954826,"node_id":"MDEyOklzc3VlQ29tbWVudDM5Nzk1NDgyNg==","user":{"login":"GeorgeTG","id":6360940,"node_id":"MDQ6VXNlcjYzNjA5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6360940?v=4","gravatar_id":"","url":"https://api.github.com/users/GeorgeTG","html_url":"https://github.com/GeorgeTG","followers_url":"https://api.github.com/users/GeorgeTG/followers","following_url":"https://api.github.com/users/GeorgeTG/following{/other_user}","gists_url":"https://api.github.com/users/GeorgeTG/gists{/gist_id}","starred_url":"https://api.github.com/users/GeorgeTG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GeorgeTG/subscriptions","organizations_url":"https://api.github.com/users/GeorgeTG/orgs","repos_url":"https://api.github.com/users/GeorgeTG/repos","events_url":"https://api.github.com/users/GeorgeTG/events{/privacy}","received_events_url":"https://api.github.com/users/GeorgeTG/received_events","type":"User","site_admin":false},"created_at":"2018-06-18T06:32:31Z","updated_at":"2018-06-18T06:32:31Z","author_association":"CONTRIBUTOR","body":"Oh yeah I couldn't merge of course"}}
{"actor":{"display_login":"GeorgeTG"}}