{"action":"created","comment":{"url":"https://api.github.com/repos/typesafehub/activator/pulls/comments/24844901","id":24844901,"diff_hunk":"@@ -18,18 +18,49 @@ define([\n   modals\n ) {\n \n-  var stream = websocket.subscribe('subType', 'BuildFailedToLoad');\n-  stream.map(function (e) {\n-    var warning = $(\"<article/>\").html(\"<p>If you are creating Typesafe Reactive Platform project you must add a '<code>typesafe.properties</code>' file in the '<code>&lt;template&gt;/project</code>' folder.</p><p>The file must contain your subscription id in the following format '<code>typesafe.subscription=&lt;YOUR ID&gt;</code>'<br/>For more information see: <a href='http://typesafe.com/subscription'>http://typesafe.com/subscription</a><p>\")[0];\n-    modals.show({\n-      shape: \"large\",\n-      title: \"Could not load project\",\n-      body: warning,\n-      cancel: \"Return\",\n-      onCancel: function() {\n-        $('#working, #open, #new').toggle();\n-      }\n-    });\n+  var failedDueToNoTypesafeProperties = false;\n+  var failedDueToNoSubscriptionId = false;\n+\n+  var sbtEventStream = websocket.subscribe('type','sbt');\n+  var subTypeEventStream = function(subType) {\n+    return sbtEventStream.matchOnAttribute('subType',subType);\n+  };\n+\n+  subTypeEventStream(\"DetachedEvent\").each(function(message) {","path":"ui/app/assets/widgets/home/home.js","position":24,"original_position":24,"commit_id":"5bfcd55bfeb7cc824006858530d3f6fc095aab26","original_commit_id":"5bfcd55bfeb7cc824006858530d3f6fc095aab26","user":{"login":"havocp","id":218689,"avatar_url":"https://avatars.githubusercontent.com/u/218689?v=3","gravatar_id":"","url":"https://api.github.com/users/havocp","html_url":"https://github.com/havocp","followers_url":"https://api.github.com/users/havocp/followers","following_url":"https://api.github.com/users/havocp/following{/other_user}","gists_url":"https://api.github.com/users/havocp/gists{/gist_id}","starred_url":"https://api.github.com/users/havocp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/havocp/subscriptions","organizations_url":"https://api.github.com/users/havocp/orgs","repos_url":"https://api.github.com/users/havocp/repos","events_url":"https://api.github.com/users/havocp/events{/privacy}","received_events_url":"https://api.github.com/users/havocp/received_events","type":"User","site_admin":false},"body":"The SubscriptionIdEvent is always before the plugin throws the exception that fails the load, so for that one yes. The SubscriptionLevelEvent and PlatformRelease event are sent async from a thread, so their order is not defined with respect to loading the build.\r\n","created_at":"2015-02-17T19:23:28Z","updated_at":"2015-02-17T19:23:28Z","html_url":"https://github.com/typesafehub/activator/pull/932#discussion_r24844901","pull_request_url":"https://api.github.com/repos/typesafehub/activator/pulls/932","_links":{"self":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/comments/24844901"},"html":{"href":"https://github.com/typesafehub/activator/pull/932#discussion_r24844901"},"pull_request":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/932"}}},"pull_request":{"url":"https://api.github.com/repos/typesafehub/activator/pulls/932","id":29459797,"html_url":"https://github.com/typesafehub/activator/pull/932","diff_url":"https://github.com/typesafehub/activator/pull/932.diff","patch_url":"https://github.com/typesafehub/activator/pull/932.patch","issue_url":"https://api.github.com/repos/typesafehub/activator/issues/932","number":932,"state":"open","locked":false,"title":"Use RP plugin events to decide warning to display","user":{"login":"havocp","id":218689,"avatar_url":"https://avatars.githubusercontent.com/u/218689?v=3","gravatar_id":"","url":"https://api.github.com/users/havocp","html_url":"https://github.com/havocp","followers_url":"https://api.github.com/users/havocp/followers","following_url":"https://api.github.com/users/havocp/following{/other_user}","gists_url":"https://api.github.com/users/havocp/gists{/gist_id}","starred_url":"https://api.github.com/users/havocp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/havocp/subscriptions","organizations_url":"https://api.github.com/users/havocp/orgs","repos_url":"https://api.github.com/users/havocp/repos","events_url":"https://api.github.com/users/havocp/events{/privacy}","received_events_url":"https://api.github.com/users/havocp/received_events","type":"User","site_admin":false},"body":"Also, add a stub to watch these events during normal operation,\r\nbut for now this just logs them.\r\n\r\nThis doesn't quite work with the current RP plugin because it doesn't throw an error and stop the build from loading when typesafe.properties is missing. However, the new one that's about to come out will do that and then this should work.\r\n\r\nI've also stubbed out here (just debug logged) the RP events for use after loading the project. However, I think this has a basic problem that we'll miss these events if we connect to sbt server after the build has already loaded. So, we may have to change this.\r\n\r\n","created_at":"2015-02-17T17:15:06Z","updated_at":"2015-02-17T19:23:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c89bd47f5630bea8e751b0166516ef193027022c","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/typesafehub/activator/pulls/932/commits","review_comments_url":"https://api.github.com/repos/typesafehub/activator/pulls/932/comments","review_comment_url":"https://api.github.com/repos/typesafehub/activator/pulls/comments/{number}","comments_url":"https://api.github.com/repos/typesafehub/activator/issues/932/comments","statuses_url":"https://api.github.com/repos/typesafehub/activator/statuses/5bfcd55bfeb7cc824006858530d3f6fc095aab26","head":{"label":"typesafehub:wip/havocp-rp-events","ref":"wip/havocp-rp-events","sha":"5bfcd55bfeb7cc824006858530d3f6fc095aab26","user":{"login":"typesafehub","id":784923,"avatar_url":"https://avatars.githubusercontent.com/u/784923?v=3","gravatar_id":"","url":"https://api.github.com/users/typesafehub","html_url":"https://github.com/typesafehub","followers_url":"https://api.github.com/users/typesafehub/followers","following_url":"https://api.github.com/users/typesafehub/following{/other_user}","gists_url":"https://api.github.com/users/typesafehub/gists{/gist_id}","starred_url":"https://api.github.com/users/typesafehub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typesafehub/subscriptions","organizations_url":"https://api.github.com/users/typesafehub/orgs","repos_url":"https://api.github.com/users/typesafehub/repos","events_url":"https://api.github.com/users/typesafehub/events{/privacy}","received_events_url":"https://api.github.com/users/typesafehub/received_events","type":"Organization","site_admin":false},"repo":{"id":11534519,"name":"activator","full_name":"typesafehub/activator","owner":{"login":"typesafehub","id":784923,"avatar_url":"https://avatars.githubusercontent.com/u/784923?v=3","gravatar_id":"","url":"https://api.github.com/users/typesafehub","html_url":"https://github.com/typesafehub","followers_url":"https://api.github.com/users/typesafehub/followers","following_url":"https://api.github.com/users/typesafehub/following{/other_user}","gists_url":"https://api.github.com/users/typesafehub/gists{/gist_id}","starred_url":"https://api.github.com/users/typesafehub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typesafehub/subscriptions","organizations_url":"https://api.github.com/users/typesafehub/orgs","repos_url":"https://api.github.com/users/typesafehub/repos","events_url":"https://api.github.com/users/typesafehub/events{/privacy}","received_events_url":"https://api.github.com/users/typesafehub/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/typesafehub/activator","description":"Typesafe Activator","fork":false,"url":"https://api.github.com/repos/typesafehub/activator","forks_url":"https://api.github.com/repos/typesafehub/activator/forks","keys_url":"https://api.github.com/repos/typesafehub/activator/keys{/key_id}","collaborators_url":"https://api.github.com/repos/typesafehub/activator/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/typesafehub/activator/teams","hooks_url":"https://api.github.com/repos/typesafehub/activator/hooks","issue_events_url":"https://api.github.com/repos/typesafehub/activator/issues/events{/number}","events_url":"https://api.github.com/repos/typesafehub/activator/events","assignees_url":"https://api.github.com/repos/typesafehub/activator/assignees{/user}","branches_url":"https://api.github.com/repos/typesafehub/activator/branches{/branch}","tags_url":"https://api.github.com/repos/typesafehub/activator/tags","blobs_url":"https://api.github.com/repos/typesafehub/activator/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/typesafehub/activator/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/typesafehub/activator/git/refs{/sha}","trees_url":"https://api.github.com/repos/typesafehub/activator/git/trees{/sha}","statuses_url":"https://api.github.com/repos/typesafehub/activator/statuses/{sha}","languages_url":"https://api.github.com/repos/typesafehub/activator/languages","stargazers_url":"https://api.github.com/repos/typesafehub/activator/stargazers","contributors_url":"https://api.github.com/repos/typesafehub/activator/contributors","subscribers_url":"https://api.github.com/repos/typesafehub/activator/subscribers","subscription_url":"https://api.github.com/repos/typesafehub/activator/subscription","commits_url":"https://api.github.com/repos/typesafehub/activator/commits{/sha}","git_commits_url":"https://api.github.com/repos/typesafehub/activator/git/commits{/sha}","comments_url":"https://api.github.com/repos/typesafehub/activator/comments{/number}","issue_comment_url":"https://api.github.com/repos/typesafehub/activator/issues/comments/{number}","contents_url":"https://api.github.com/repos/typesafehub/activator/contents/{+path}","compare_url":"https://api.github.com/repos/typesafehub/activator/compare/{base}...{head}","merges_url":"https://api.github.com/repos/typesafehub/activator/merges","archive_url":"https://api.github.com/repos/typesafehub/activator/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/typesafehub/activator/downloads","issues_url":"https://api.github.com/repos/typesafehub/activator/issues{/number}","pulls_url":"https://api.github.com/repos/typesafehub/activator/pulls{/number}","milestones_url":"https://api.github.com/repos/typesafehub/activator/milestones{/number}","notifications_url":"https://api.github.com/repos/typesafehub/activator/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/typesafehub/activator/labels{/name}","releases_url":"https://api.github.com/repos/typesafehub/activator/releases{/id}","created_at":"2013-07-19T18:35:50Z","updated_at":"2015-02-17T17:04:51Z","pushed_at":"2015-02-17T17:09:39Z","git_url":"git://github.com/typesafehub/activator.git","ssh_url":"git@github.com:typesafehub/activator.git","clone_url":"https://github.com/typesafehub/activator.git","svn_url":"https://github.com/typesafehub/activator","homepage":"http://typesafe.com/activator","size":35371,"stargazers_count":258,"watchers_count":258,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":75,"mirror_url":null,"open_issues_count":73,"forks":75,"open_issues":73,"watchers":258,"default_branch":"master"}},"base":{"label":"typesafehub:master","ref":"master","sha":"51bc3ccb98ed6ca24e73007ca13b74824a6da02b","user":{"login":"typesafehub","id":784923,"avatar_url":"https://avatars.githubusercontent.com/u/784923?v=3","gravatar_id":"","url":"https://api.github.com/users/typesafehub","html_url":"https://github.com/typesafehub","followers_url":"https://api.github.com/users/typesafehub/followers","following_url":"https://api.github.com/users/typesafehub/following{/other_user}","gists_url":"https://api.github.com/users/typesafehub/gists{/gist_id}","starred_url":"https://api.github.com/users/typesafehub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typesafehub/subscriptions","organizations_url":"https://api.github.com/users/typesafehub/orgs","repos_url":"https://api.github.com/users/typesafehub/repos","events_url":"https://api.github.com/users/typesafehub/events{/privacy}","received_events_url":"https://api.github.com/users/typesafehub/received_events","type":"Organization","site_admin":false},"repo":{"id":11534519,"name":"activator","full_name":"typesafehub/activator","owner":{"login":"typesafehub","id":784923,"avatar_url":"https://avatars.githubusercontent.com/u/784923?v=3","gravatar_id":"","url":"https://api.github.com/users/typesafehub","html_url":"https://github.com/typesafehub","followers_url":"https://api.github.com/users/typesafehub/followers","following_url":"https://api.github.com/users/typesafehub/following{/other_user}","gists_url":"https://api.github.com/users/typesafehub/gists{/gist_id}","starred_url":"https://api.github.com/users/typesafehub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typesafehub/subscriptions","organizations_url":"https://api.github.com/users/typesafehub/orgs","repos_url":"https://api.github.com/users/typesafehub/repos","events_url":"https://api.github.com/users/typesafehub/events{/privacy}","received_events_url":"https://api.github.com/users/typesafehub/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/typesafehub/activator","description":"Typesafe Activator","fork":false,"url":"https://api.github.com/repos/typesafehub/activator","forks_url":"https://api.github.com/repos/typesafehub/activator/forks","keys_url":"https://api.github.com/repos/typesafehub/activator/keys{/key_id}","collaborators_url":"https://api.github.com/repos/typesafehub/activator/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/typesafehub/activator/teams","hooks_url":"https://api.github.com/repos/typesafehub/activator/hooks","issue_events_url":"https://api.github.com/repos/typesafehub/activator/issues/events{/number}","events_url":"https://api.github.com/repos/typesafehub/activator/events","assignees_url":"https://api.github.com/repos/typesafehub/activator/assignees{/user}","branches_url":"https://api.github.com/repos/typesafehub/activator/branches{/branch}","tags_url":"https://api.github.com/repos/typesafehub/activator/tags","blobs_url":"https://api.github.com/repos/typesafehub/activator/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/typesafehub/activator/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/typesafehub/activator/git/refs{/sha}","trees_url":"https://api.github.com/repos/typesafehub/activator/git/trees{/sha}","statuses_url":"https://api.github.com/repos/typesafehub/activator/statuses/{sha}","languages_url":"https://api.github.com/repos/typesafehub/activator/languages","stargazers_url":"https://api.github.com/repos/typesafehub/activator/stargazers","contributors_url":"https://api.github.com/repos/typesafehub/activator/contributors","subscribers_url":"https://api.github.com/repos/typesafehub/activator/subscribers","subscription_url":"https://api.github.com/repos/typesafehub/activator/subscription","commits_url":"https://api.github.com/repos/typesafehub/activator/commits{/sha}","git_commits_url":"https://api.github.com/repos/typesafehub/activator/git/commits{/sha}","comments_url":"https://api.github.com/repos/typesafehub/activator/comments{/number}","issue_comment_url":"https://api.github.com/repos/typesafehub/activator/issues/comments/{number}","contents_url":"https://api.github.com/repos/typesafehub/activator/contents/{+path}","compare_url":"https://api.github.com/repos/typesafehub/activator/compare/{base}...{head}","merges_url":"https://api.github.com/repos/typesafehub/activator/merges","archive_url":"https://api.github.com/repos/typesafehub/activator/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/typesafehub/activator/downloads","issues_url":"https://api.github.com/repos/typesafehub/activator/issues{/number}","pulls_url":"https://api.github.com/repos/typesafehub/activator/pulls{/number}","milestones_url":"https://api.github.com/repos/typesafehub/activator/milestones{/number}","notifications_url":"https://api.github.com/repos/typesafehub/activator/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/typesafehub/activator/labels{/name}","releases_url":"https://api.github.com/repos/typesafehub/activator/releases{/id}","created_at":"2013-07-19T18:35:50Z","updated_at":"2015-02-17T17:04:51Z","pushed_at":"2015-02-17T17:09:39Z","git_url":"git://github.com/typesafehub/activator.git","ssh_url":"git@github.com:typesafehub/activator.git","clone_url":"https://github.com/typesafehub/activator.git","svn_url":"https://github.com/typesafehub/activator","homepage":"http://typesafe.com/activator","size":35371,"stargazers_count":258,"watchers_count":258,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":75,"mirror_url":null,"open_issues_count":73,"forks":75,"open_issues":73,"watchers":258,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/932"},"html":{"href":"https://github.com/typesafehub/activator/pull/932"},"issue":{"href":"https://api.github.com/repos/typesafehub/activator/issues/932"},"comments":{"href":"https://api.github.com/repos/typesafehub/activator/issues/932/comments"},"review_comments":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/932/comments"},"review_comment":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/typesafehub/activator/pulls/932/commits"},"statuses":{"href":"https://api.github.com/repos/typesafehub/activator/statuses/5bfcd55bfeb7cc824006858530d3f6fc095aab26"}}}}