{"action":"created","comment":{"url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/comments/210944355","pull_request_review_id":147270548,"id":210944355,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxMDk0NDM1NQ==","diff_hunk":"@@ -45,10 +46,11 @@ export function getEnricherOrDieTryin(store, currentWindow) {\n     const user = _.pick(currentUser, ['access_level', 'customer', 'username']);\n     const fromOurBundle = isErrorFromOurBundle(data);\n     const apiError = isApiError(data);\n+    const isSupportedBrowser = isErrorInSupportedBrowser();\n \n     return {\n       ...data,\n-      level: !fromOurBundle || apiError ? 'warning' : 'error',\n+      level: apiError || (fromOurBundle && !isSupportedBrowser) ? 'warning' : 'error',","path":"src/helpers/errorTracker.js","position":17,"original_position":17,"commit_id":"c65ddd5c504e388c3d4fca53119fbfbbc4e77beb","original_commit_id":"c65ddd5c504e388c3d4fca53119fbfbbc4e77beb","user":{"login":"bkemper","id":1335605,"node_id":"MDQ6VXNlcjEzMzU2MDU=","avatar_url":"https://avatars3.githubusercontent.com/u/1335605?v=4","gravatar_id":"","url":"https://api.github.com/users/bkemper","html_url":"https://github.com/bkemper","followers_url":"https://api.github.com/users/bkemper/followers","following_url":"https://api.github.com/users/bkemper/following{/other_user}","gists_url":"https://api.github.com/users/bkemper/gists{/gist_id}","starred_url":"https://api.github.com/users/bkemper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bkemper/subscriptions","organizations_url":"https://api.github.com/users/bkemper/orgs","repos_url":"https://api.github.com/users/bkemper/repos","events_url":"https://api.github.com/users/bkemper/events{/privacy}","received_events_url":"https://api.github.com/users/bkemper/received_events","type":"User","site_admin":false},"body":"Yep, and my suggestion should work for that case.","created_at":"2018-08-17T15:20:21Z","updated_at":"2018-08-17T15:20:21Z","html_url":"https://github.com/SparkPost/2web2ui/pull/579#discussion_r210944355","pull_request_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/comments/210944355"},"html":{"href":"https://github.com/SparkPost/2web2ui/pull/579#discussion_r210944355"},"pull_request":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579"}},"in_reply_to_id":210403219},"pull_request":{"url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579","id":208161293,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA4MTYxMjkz","html_url":"https://github.com/SparkPost/2web2ui/pull/579","diff_url":"https://github.com/SparkPost/2web2ui/pull/579.diff","patch_url":"https://github.com/SparkPost/2web2ui/pull/579.patch","issue_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/579","number":579,"state":"open","locked":false,"title":"FE-446 Mark unsupported browser errors as warning on Sentry","user":{"login":"rajumsys","id":14877079,"node_id":"MDQ6VXNlcjE0ODc3MDc5","avatar_url":"https://avatars0.githubusercontent.com/u/14877079?v=4","gravatar_id":"","url":"https://api.github.com/users/rajumsys","html_url":"https://github.com/rajumsys","followers_url":"https://api.github.com/users/rajumsys/followers","following_url":"https://api.github.com/users/rajumsys/following{/other_user}","gists_url":"https://api.github.com/users/rajumsys/gists{/gist_id}","starred_url":"https://api.github.com/users/rajumsys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rajumsys/subscriptions","organizations_url":"https://api.github.com/users/rajumsys/orgs","repos_url":"https://api.github.com/users/rajumsys/repos","events_url":"https://api.github.com/users/rajumsys/events{/privacy}","received_events_url":"https://api.github.com/users/rajumsys/received_events","type":"User","site_admin":false},"body":"This runs `browsersSnapshotGen` during build and returns a list of browsers on mobile and desktop. Later this is checked against the useragent to set level in sentry errors. \r\n\r\n-  [Webpack Define Plugin](https://webpack.js.org/plugins/define-plugin/) is used. This replaces the variable `SUPPORTED_BROWSERS` with browsers snapshot during build time. \r\n- Because the variable `SUPPORTED_BROWSERS` is not defined anywhere and gets replaced during build time, linting throws error. So, i've added exception. \r\n- Used `bowser` package even though it's in alpha. So i've locked to specific version that works for us. It solves our problem of pretty neatly. Dev seems rapid so I guess there will be stable release soon. \r\n- It's little difficult to make sure whether the browser names mapping will work exactly as it is written on those particular browsers. But we can fix it if we still notice issues are not tagged correctly. \r\n- added same variable as global in jest configuration so that tests doesn't fail. \r\n\r\n\r\n**Further thought:**\r\nThough it should work fine now, I'm not sure whether this feels like a little magic and may be very clear to next person. My initial approach was much clearer which is as follows:\r\n- I've created `browsers` in a root directory (outside src) as I didn't want to have auto generated file inside `src` . This directory contains browsersSnapshotGen.js. However, when run this file will create a  new file in same directory with exactly same data (whatever `generate` func returns)\r\n- I've added this file (snapshot) in webpack's entry points. This file will be re-generated each time we run `npm start` or `npm run build`. But as long as browsers rule doesn't change or browserlist doesn't change, it'll be same content. Once content changes, it'll update the snapshot which will be clearly visible as we'll see the diff. We could also limit snapshot generator only during development (`npm start`) so production build will always use that. \r\n- From source codes i could reference it like `import browserSnapshots from 'browsers/snapshot'` and rest of the things are business usual! \r\n","created_at":"2018-08-14T03:45:15Z","updated_at":"2018-08-17T15:20:21Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f5ee6346129b68eabbbea58acd6808b14c840b11","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579/commits","review_comments_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579/comments","review_comment_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/579/comments","statuses_url":"https://api.github.com/repos/SparkPost/2web2ui/statuses/c65ddd5c504e388c3d4fca53119fbfbbc4e77beb","head":{"label":"SparkPost:hotfix/FE-446","ref":"hotfix/FE-446","sha":"c65ddd5c504e388c3d4fca53119fbfbbc4e77beb","user":{"login":"SparkPost","id":9406778,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk0MDY3Nzg=","avatar_url":"https://avatars0.githubusercontent.com/u/9406778?v=4","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"repo":{"id":91982173,"node_id":"MDEwOlJlcG9zaXRvcnk5MTk4MjE3Mw==","name":"2web2ui","full_name":"SparkPost/2web2ui","owner":{"login":"SparkPost","id":9406778,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk0MDY3Nzg=","avatar_url":"https://avatars0.githubusercontent.com/u/9406778?v=4","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SparkPost/2web2ui","description":"A React-powered app for the SparkPost email service.","fork":false,"url":"https://api.github.com/repos/SparkPost/2web2ui","forks_url":"https://api.github.com/repos/SparkPost/2web2ui/forks","keys_url":"https://api.github.com/repos/SparkPost/2web2ui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SparkPost/2web2ui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SparkPost/2web2ui/teams","hooks_url":"https://api.github.com/repos/SparkPost/2web2ui/hooks","issue_events_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/events{/number}","events_url":"https://api.github.com/repos/SparkPost/2web2ui/events","assignees_url":"https://api.github.com/repos/SparkPost/2web2ui/assignees{/user}","branches_url":"https://api.github.com/repos/SparkPost/2web2ui/branches{/branch}","tags_url":"https://api.github.com/repos/SparkPost/2web2ui/tags","blobs_url":"https://api.github.com/repos/SparkPost/2web2ui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SparkPost/2web2ui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SparkPost/2web2ui/git/refs{/sha}","trees_url":"https://api.github.com/repos/SparkPost/2web2ui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SparkPost/2web2ui/statuses/{sha}","languages_url":"https://api.github.com/repos/SparkPost/2web2ui/languages","stargazers_url":"https://api.github.com/repos/SparkPost/2web2ui/stargazers","contributors_url":"https://api.github.com/repos/SparkPost/2web2ui/contributors","subscribers_url":"https://api.github.com/repos/SparkPost/2web2ui/subscribers","subscription_url":"https://api.github.com/repos/SparkPost/2web2ui/subscription","commits_url":"https://api.github.com/repos/SparkPost/2web2ui/commits{/sha}","git_commits_url":"https://api.github.com/repos/SparkPost/2web2ui/git/commits{/sha}","comments_url":"https://api.github.com/repos/SparkPost/2web2ui/comments{/number}","issue_comment_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/comments{/number}","contents_url":"https://api.github.com/repos/SparkPost/2web2ui/contents/{+path}","compare_url":"https://api.github.com/repos/SparkPost/2web2ui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SparkPost/2web2ui/merges","archive_url":"https://api.github.com/repos/SparkPost/2web2ui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SparkPost/2web2ui/downloads","issues_url":"https://api.github.com/repos/SparkPost/2web2ui/issues{/number}","pulls_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls{/number}","milestones_url":"https://api.github.com/repos/SparkPost/2web2ui/milestones{/number}","notifications_url":"https://api.github.com/repos/SparkPost/2web2ui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SparkPost/2web2ui/labels{/name}","releases_url":"https://api.github.com/repos/SparkPost/2web2ui/releases{/id}","deployments_url":"https://api.github.com/repos/SparkPost/2web2ui/deployments","created_at":"2017-05-21T19:31:03Z","updated_at":"2018-08-16T20:19:20Z","pushed_at":"2018-08-16T21:19:59Z","git_url":"git://github.com/SparkPost/2web2ui.git","ssh_url":"git@github.com:SparkPost/2web2ui.git","clone_url":"https://github.com/SparkPost/2web2ui.git","svn_url":"https://github.com/SparkPost/2web2ui","homepage":"https://sparkpost.com","size":21497,"stargazers_count":11,"watchers_count":11,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":35,"license":null,"forks":2,"open_issues":35,"watchers":11,"default_branch":"master"}},"base":{"label":"SparkPost:master","ref":"master","sha":"5ab549d2b5ec73bff076f5ecc3a98a2f428e5fb0","user":{"login":"SparkPost","id":9406778,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk0MDY3Nzg=","avatar_url":"https://avatars0.githubusercontent.com/u/9406778?v=4","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"repo":{"id":91982173,"node_id":"MDEwOlJlcG9zaXRvcnk5MTk4MjE3Mw==","name":"2web2ui","full_name":"SparkPost/2web2ui","owner":{"login":"SparkPost","id":9406778,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk0MDY3Nzg=","avatar_url":"https://avatars0.githubusercontent.com/u/9406778?v=4","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SparkPost/2web2ui","description":"A React-powered app for the SparkPost email service.","fork":false,"url":"https://api.github.com/repos/SparkPost/2web2ui","forks_url":"https://api.github.com/repos/SparkPost/2web2ui/forks","keys_url":"https://api.github.com/repos/SparkPost/2web2ui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SparkPost/2web2ui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SparkPost/2web2ui/teams","hooks_url":"https://api.github.com/repos/SparkPost/2web2ui/hooks","issue_events_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/events{/number}","events_url":"https://api.github.com/repos/SparkPost/2web2ui/events","assignees_url":"https://api.github.com/repos/SparkPost/2web2ui/assignees{/user}","branches_url":"https://api.github.com/repos/SparkPost/2web2ui/branches{/branch}","tags_url":"https://api.github.com/repos/SparkPost/2web2ui/tags","blobs_url":"https://api.github.com/repos/SparkPost/2web2ui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SparkPost/2web2ui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SparkPost/2web2ui/git/refs{/sha}","trees_url":"https://api.github.com/repos/SparkPost/2web2ui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SparkPost/2web2ui/statuses/{sha}","languages_url":"https://api.github.com/repos/SparkPost/2web2ui/languages","stargazers_url":"https://api.github.com/repos/SparkPost/2web2ui/stargazers","contributors_url":"https://api.github.com/repos/SparkPost/2web2ui/contributors","subscribers_url":"https://api.github.com/repos/SparkPost/2web2ui/subscribers","subscription_url":"https://api.github.com/repos/SparkPost/2web2ui/subscription","commits_url":"https://api.github.com/repos/SparkPost/2web2ui/commits{/sha}","git_commits_url":"https://api.github.com/repos/SparkPost/2web2ui/git/commits{/sha}","comments_url":"https://api.github.com/repos/SparkPost/2web2ui/comments{/number}","issue_comment_url":"https://api.github.com/repos/SparkPost/2web2ui/issues/comments{/number}","contents_url":"https://api.github.com/repos/SparkPost/2web2ui/contents/{+path}","compare_url":"https://api.github.com/repos/SparkPost/2web2ui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SparkPost/2web2ui/merges","archive_url":"https://api.github.com/repos/SparkPost/2web2ui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SparkPost/2web2ui/downloads","issues_url":"https://api.github.com/repos/SparkPost/2web2ui/issues{/number}","pulls_url":"https://api.github.com/repos/SparkPost/2web2ui/pulls{/number}","milestones_url":"https://api.github.com/repos/SparkPost/2web2ui/milestones{/number}","notifications_url":"https://api.github.com/repos/SparkPost/2web2ui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SparkPost/2web2ui/labels{/name}","releases_url":"https://api.github.com/repos/SparkPost/2web2ui/releases{/id}","deployments_url":"https://api.github.com/repos/SparkPost/2web2ui/deployments","created_at":"2017-05-21T19:31:03Z","updated_at":"2018-08-16T20:19:20Z","pushed_at":"2018-08-16T21:19:59Z","git_url":"git://github.com/SparkPost/2web2ui.git","ssh_url":"git@github.com:SparkPost/2web2ui.git","clone_url":"https://github.com/SparkPost/2web2ui.git","svn_url":"https://github.com/SparkPost/2web2ui","homepage":"https://sparkpost.com","size":21497,"stargazers_count":11,"watchers_count":11,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":35,"license":null,"forks":2,"open_issues":35,"watchers":11,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579"},"html":{"href":"https://github.com/SparkPost/2web2ui/pull/579"},"issue":{"href":"https://api.github.com/repos/SparkPost/2web2ui/issues/579"},"comments":{"href":"https://api.github.com/repos/SparkPost/2web2ui/issues/579/comments"},"review_comments":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579/comments"},"review_comment":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SparkPost/2web2ui/pulls/579/commits"},"statuses":{"href":"https://api.github.com/repos/SparkPost/2web2ui/statuses/c65ddd5c504e388c3d4fca53119fbfbbc4e77beb"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"bkemper"}}