{"action":"created","comment":{"url":"https://api.github.com/repos/influxdata/platform/pulls/comments/233662447","pull_request_review_id":175127762,"id":233662447,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMzY2MjQ0Nw==","diff_hunk":"@@ -0,0 +1,20 @@\n+import {AppState, Source} from 'src/types/v2'\n+\n+export const getActiveSource = (state: AppState): Source | null => {\n+  const {activeSourceID} = state.sources\n+\n+  if (!activeSourceID) {\n+    return null\n+  }\n+\n+  const source = state.sources.sources[activeSourceID]","path":"ui/src/sources/selectors/index.ts","position":10,"original_position":10,"commit_id":"9083f3efdc565f7690cd0b40472e786df0fd0fc1","original_commit_id":"9083f3efdc565f7690cd0b40472e786df0fd0fc1","user":{"login":"jaredscheib","id":6403018,"node_id":"MDQ6VXNlcjY0MDMwMTg=","avatar_url":"https://avatars1.githubusercontent.com/u/6403018?v=4","gravatar_id":"","url":"https://api.github.com/users/jaredscheib","html_url":"https://github.com/jaredscheib","followers_url":"https://api.github.com/users/jaredscheib/followers","following_url":"https://api.github.com/users/jaredscheib/following{/other_user}","gists_url":"https://api.github.com/users/jaredscheib/gists{/gist_id}","starred_url":"https://api.github.com/users/jaredscheib/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaredscheib/subscriptions","organizations_url":"https://api.github.com/users/jaredscheib/orgs","repos_url":"https://api.github.com/users/jaredscheib/repos","events_url":"https://api.github.com/users/jaredscheib/events{/privacy}","received_events_url":"https://api.github.com/users/jaredscheib/received_events","type":"User","site_admin":false},"body":"any chance this lookup fails at some level of nesting?","created_at":"2018-11-14T23:33:51Z","updated_at":"2018-11-14T23:34:47Z","html_url":"https://github.com/influxdata/platform/pull/1406#discussion_r233662447","pull_request_url":"https://api.github.com/repos/influxdata/platform/pulls/1406","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/influxdata/platform/pulls/comments/233662447"},"html":{"href":"https://github.com/influxdata/platform/pull/1406#discussion_r233662447"},"pull_request":{"href":"https://api.github.com/repos/influxdata/platform/pulls/1406"}}},"pull_request":{"url":"https://api.github.com/repos/influxdata/platform/pulls/1406","id":231007309,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMxMDA3MzA5","html_url":"https://github.com/influxdata/platform/pull/1406","diff_url":"https://github.com/influxdata/platform/pull/1406.diff","patch_url":"https://github.com/influxdata/platform/pull/1406.patch","issue_url":"https://api.github.com/repos/influxdata/platform/issues/1406","number":1406,"state":"open","locked":false,"title":"Add initial source management UI","user":{"login":"chnn","id":638955,"node_id":"MDQ6VXNlcjYzODk1NQ==","avatar_url":"https://avatars0.githubusercontent.com/u/638955?v=4","gravatar_id":"","url":"https://api.github.com/users/chnn","html_url":"https://github.com/chnn","followers_url":"https://api.github.com/users/chnn/followers","following_url":"https://api.github.com/users/chnn/following{/other_user}","gists_url":"https://api.github.com/users/chnn/gists{/gist_id}","starred_url":"https://api.github.com/users/chnn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chnn/subscriptions","organizations_url":"https://api.github.com/users/chnn/orgs","repos_url":"https://api.github.com/users/chnn/repos","events_url":"https://api.github.com/users/chnn/events{/privacy}","received_events_url":"https://api.github.com/users/chnn/received_events","type":"User","site_admin":false},"body":"- Adds a simple UI for listing sources, adding a new source, deleting a source, and switching the active source\r\n- Normalizes the schema used to store sources in Redux\r\n- Makes Redux the state of truth for the currently active source, rather than the query param (the query param will stay synced via the `SetActiveSource` component)\r\n- Fixes the inability to navigate backwards after switching to certain pages\r\n\r\n<img width=\"1103\" alt=\"screen shot 2018-11-14 at 2 37 07 pm\" src=\"https://user-images.githubusercontent.com/638955/48517477-44277e00-e81b-11e8-8665-93d24807ef80.png\">\r\n\r\n<img width=\"1103\" alt=\"screen shot 2018-11-14 at 2 37 04 pm\" src=\"https://user-images.githubusercontent.com/638955/48517480-4689d800-e81b-11e8-82b2-b81d446edeb2.png\">","created_at":"2018-11-14T22:41:11Z","updated_at":"2018-11-14T23:34:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8953be647eaeccc2003bbade9d7123e1671f6564","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/influxdata/platform/pulls/1406/commits","review_comments_url":"https://api.github.com/repos/influxdata/platform/pulls/1406/comments","review_comment_url":"https://api.github.com/repos/influxdata/platform/pulls/comments{/number}","comments_url":"https://api.github.com/repos/influxdata/platform/issues/1406/comments","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/9083f3efdc565f7690cd0b40472e786df0fd0fc1","head":{"label":"influxdata:sources-page","ref":"sources-page","sha":"9083f3efdc565f7690cd0b40472e786df0fd0fc1","user":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"repo":{"id":132783164,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI3ODMxNjQ=","name":"platform","full_name":"influxdata/platform","private":false,"owner":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/influxdata/platform","description":"InfluxDB 2.0: The community version of the InfluxData Platform for Time Series","fork":false,"url":"https://api.github.com/repos/influxdata/platform","forks_url":"https://api.github.com/repos/influxdata/platform/forks","keys_url":"https://api.github.com/repos/influxdata/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/influxdata/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/influxdata/platform/teams","hooks_url":"https://api.github.com/repos/influxdata/platform/hooks","issue_events_url":"https://api.github.com/repos/influxdata/platform/issues/events{/number}","events_url":"https://api.github.com/repos/influxdata/platform/events","assignees_url":"https://api.github.com/repos/influxdata/platform/assignees{/user}","branches_url":"https://api.github.com/repos/influxdata/platform/branches{/branch}","tags_url":"https://api.github.com/repos/influxdata/platform/tags","blobs_url":"https://api.github.com/repos/influxdata/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/influxdata/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/influxdata/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/influxdata/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/influxdata/platform/languages","stargazers_url":"https://api.github.com/repos/influxdata/platform/stargazers","contributors_url":"https://api.github.com/repos/influxdata/platform/contributors","subscribers_url":"https://api.github.com/repos/influxdata/platform/subscribers","subscription_url":"https://api.github.com/repos/influxdata/platform/subscription","commits_url":"https://api.github.com/repos/influxdata/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/influxdata/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/influxdata/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/influxdata/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/influxdata/platform/contents/{+path}","compare_url":"https://api.github.com/repos/influxdata/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/influxdata/platform/merges","archive_url":"https://api.github.com/repos/influxdata/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/influxdata/platform/downloads","issues_url":"https://api.github.com/repos/influxdata/platform/issues{/number}","pulls_url":"https://api.github.com/repos/influxdata/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/influxdata/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/influxdata/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/influxdata/platform/labels{/name}","releases_url":"https://api.github.com/repos/influxdata/platform/releases{/id}","deployments_url":"https://api.github.com/repos/influxdata/platform/deployments","created_at":"2018-05-09T16:17:29Z","updated_at":"2018-11-14T23:16:28Z","pushed_at":"2018-11-14T23:34:03Z","git_url":"git://github.com/influxdata/platform.git","ssh_url":"git@github.com:influxdata/platform.git","clone_url":"https://github.com/influxdata/platform.git","svn_url":"https://github.com/influxdata/platform","homepage":"","size":35874,"stargazers_count":173,"watchers_count":173,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":16,"mirror_url":null,"archived":false,"open_issues_count":408,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":16,"open_issues":408,"watchers":173,"default_branch":"master"}},"base":{"label":"influxdata:master","ref":"master","sha":"24968bc6b086c7b92be7b571de478f36f56e3d3e","user":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"repo":{"id":132783164,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI3ODMxNjQ=","name":"platform","full_name":"influxdata/platform","private":false,"owner":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/influxdata/platform","description":"InfluxDB 2.0: The community version of the InfluxData Platform for Time Series","fork":false,"url":"https://api.github.com/repos/influxdata/platform","forks_url":"https://api.github.com/repos/influxdata/platform/forks","keys_url":"https://api.github.com/repos/influxdata/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/influxdata/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/influxdata/platform/teams","hooks_url":"https://api.github.com/repos/influxdata/platform/hooks","issue_events_url":"https://api.github.com/repos/influxdata/platform/issues/events{/number}","events_url":"https://api.github.com/repos/influxdata/platform/events","assignees_url":"https://api.github.com/repos/influxdata/platform/assignees{/user}","branches_url":"https://api.github.com/repos/influxdata/platform/branches{/branch}","tags_url":"https://api.github.com/repos/influxdata/platform/tags","blobs_url":"https://api.github.com/repos/influxdata/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/influxdata/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/influxdata/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/influxdata/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/influxdata/platform/languages","stargazers_url":"https://api.github.com/repos/influxdata/platform/stargazers","contributors_url":"https://api.github.com/repos/influxdata/platform/contributors","subscribers_url":"https://api.github.com/repos/influxdata/platform/subscribers","subscription_url":"https://api.github.com/repos/influxdata/platform/subscription","commits_url":"https://api.github.com/repos/influxdata/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/influxdata/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/influxdata/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/influxdata/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/influxdata/platform/contents/{+path}","compare_url":"https://api.github.com/repos/influxdata/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/influxdata/platform/merges","archive_url":"https://api.github.com/repos/influxdata/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/influxdata/platform/downloads","issues_url":"https://api.github.com/repos/influxdata/platform/issues{/number}","pulls_url":"https://api.github.com/repos/influxdata/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/influxdata/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/influxdata/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/influxdata/platform/labels{/name}","releases_url":"https://api.github.com/repos/influxdata/platform/releases{/id}","deployments_url":"https://api.github.com/repos/influxdata/platform/deployments","created_at":"2018-05-09T16:17:29Z","updated_at":"2018-11-14T23:16:28Z","pushed_at":"2018-11-14T23:34:03Z","git_url":"git://github.com/influxdata/platform.git","ssh_url":"git@github.com:influxdata/platform.git","clone_url":"https://github.com/influxdata/platform.git","svn_url":"https://github.com/influxdata/platform","homepage":"","size":35874,"stargazers_count":173,"watchers_count":173,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":16,"mirror_url":null,"archived":false,"open_issues_count":408,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":16,"open_issues":408,"watchers":173,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/influxdata/platform/pulls/1406"},"html":{"href":"https://github.com/influxdata/platform/pull/1406"},"issue":{"href":"https://api.github.com/repos/influxdata/platform/issues/1406"},"comments":{"href":"https://api.github.com/repos/influxdata/platform/issues/1406/comments"},"review_comments":{"href":"https://api.github.com/repos/influxdata/platform/pulls/1406/comments"},"review_comment":{"href":"https://api.github.com/repos/influxdata/platform/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/influxdata/platform/pulls/1406/commits"},"statuses":{"href":"https://api.github.com/repos/influxdata/platform/statuses/9083f3efdc565f7690cd0b40472e786df0fd0fc1"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"jaredscheib"}}