{"action":"created","comment":{"url":"https://api.github.com/repos/ganga-devs/ganga/pulls/comments/64207418","id":64207418,"diff_hunk":"@@ -877,9 +877,17 @@ def info(self, full=False):\n                 s += \", %i other concurrent sessions:\\n * %s\" % (len(other_sessions), \"\\n * \".join(other_sessions))\n         return s\n \n+    def other_session_active(self):\n+        \"\"\" Returns a True/False for if other sessions have been detected from the Repository \"\"\"\n+        if self.repository.get_other_sessions():\n+            return True\n+        else:\n+            return False\n+\n     def print_other_sessions(self):\n-        other_sessions = self.repository.get_other_sessions()\n-        if len(other_sessions) > 0:\n+        \"\"\" Prints a warning if other active sessions have been detected \"\"\"\n+        if self.other_session_active():\n+            other_sessions = self.repository.get_other_sessions()","path":"python/Ganga/Core/GangaRepository/Registry.py","position":16,"original_position":16,"commit_id":"108254bf70dc117ea58840a7dafee74d1e1fdc0c","original_commit_id":"108254bf70dc117ea58840a7dafee74d1e1fdc0c","user":{"login":"milliams","id":61316,"avatar_url":"https://avatars.githubusercontent.com/u/61316?v=3","gravatar_id":"","url":"https://api.github.com/users/milliams","html_url":"https://github.com/milliams","followers_url":"https://api.github.com/users/milliams/followers","following_url":"https://api.github.com/users/milliams/following{/other_user}","gists_url":"https://api.github.com/users/milliams/gists{/gist_id}","starred_url":"https://api.github.com/users/milliams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/milliams/subscriptions","organizations_url":"https://api.github.com/users/milliams/orgs","repos_url":"https://api.github.com/users/milliams/repos","events_url":"https://api.github.com/users/milliams/events{/privacy}","received_events_url":"https://api.github.com/users/milliams/received_events","type":"User","site_admin":false},"body":"Because it's the repository that we care about. Registries don't have 'other sessions' since they are in in-memory construct. It is the repository that can care about other processes and we want to know if there are other processes reading the files on dick. Accessing the repository from the registry is fine; it's accessing the registry from the repository that is bad in my opinion.","created_at":"2016-05-23T11:31:51Z","updated_at":"2016-05-23T11:31:51Z","html_url":"https://github.com/ganga-devs/ganga/pull/507#discussion_r64207418","pull_request_url":"https://api.github.com/repos/ganga-devs/ganga/pulls/507","_links":{"self":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/comments/64207418"},"html":{"href":"https://github.com/ganga-devs/ganga/pull/507#discussion_r64207418"},"pull_request":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/507"}}},"pull_request":{"url":"https://api.github.com/repos/ganga-devs/ganga/pulls/507","id":71037184,"html_url":"https://github.com/ganga-devs/ganga/pull/507","diff_url":"https://github.com/ganga-devs/ganga/pull/507.diff","patch_url":"https://github.com/ganga-devs/ganga/pull/507.patch","issue_url":"https://api.github.com/repos/ganga-devs/ganga/issues/507","number":507,"state":"open","locked":false,"title":"Feature/no multiple mon loops","user":{"login":"rob-c","id":1102021,"avatar_url":"https://avatars.githubusercontent.com/u/1102021?v=3","gravatar_id":"","url":"https://api.github.com/users/rob-c","html_url":"https://github.com/rob-c","followers_url":"https://api.github.com/users/rob-c/followers","following_url":"https://api.github.com/users/rob-c/following{/other_user}","gists_url":"https://api.github.com/users/rob-c/gists{/gist_id}","starred_url":"https://api.github.com/users/rob-c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rob-c/subscriptions","organizations_url":"https://api.github.com/users/rob-c/orgs","repos_url":"https://api.github.com/users/rob-c/repos","events_url":"https://api.github.com/users/rob-c/events{/privacy}","received_events_url":"https://api.github.com/users/rob-c/received_events","type":"User","site_admin":false},"body":"This PR turns off the monitoring loop when other another Ganga session is found to be running on a repo.\r\nThis should be possible to override by typing ```enableMonitoring``` from the interactive prompt if the monitoring loop is expected to run no matter what.\r\n\r\nI've also included some code cleanup I have against ```SessionLock``` as well as a synchronize method against the GangaThread as I've seen threads change running state whilst running based upon the input from other threads so I thought it best just to keep each thread consistent even if this should rarely happen.\r\n\r\nFixes #236","created_at":"2016-05-23T10:19:35Z","updated_at":"2016-05-23T11:31:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b7bd08228950a2ba560330ad8e0e315e2b47235d","assignee":{"login":"rob-c","id":1102021,"avatar_url":"https://avatars.githubusercontent.com/u/1102021?v=3","gravatar_id":"","url":"https://api.github.com/users/rob-c","html_url":"https://github.com/rob-c","followers_url":"https://api.github.com/users/rob-c/followers","following_url":"https://api.github.com/users/rob-c/following{/other_user}","gists_url":"https://api.github.com/users/rob-c/gists{/gist_id}","starred_url":"https://api.github.com/users/rob-c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rob-c/subscriptions","organizations_url":"https://api.github.com/users/rob-c/orgs","repos_url":"https://api.github.com/users/rob-c/repos","events_url":"https://api.github.com/users/rob-c/events{/privacy}","received_events_url":"https://api.github.com/users/rob-c/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/ganga-devs/ganga/pulls/507/commits","review_comments_url":"https://api.github.com/repos/ganga-devs/ganga/pulls/507/comments","review_comment_url":"https://api.github.com/repos/ganga-devs/ganga/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ganga-devs/ganga/issues/507/comments","statuses_url":"https://api.github.com/repos/ganga-devs/ganga/statuses/108254bf70dc117ea58840a7dafee74d1e1fdc0c","head":{"label":"ganga-devs:feature/noMultipleMonLoops","ref":"feature/noMultipleMonLoops","sha":"108254bf70dc117ea58840a7dafee74d1e1fdc0c","user":{"login":"ganga-devs","id":13271048,"avatar_url":"https://avatars.githubusercontent.com/u/13271048?v=3","gravatar_id":"","url":"https://api.github.com/users/ganga-devs","html_url":"https://github.com/ganga-devs","followers_url":"https://api.github.com/users/ganga-devs/followers","following_url":"https://api.github.com/users/ganga-devs/following{/other_user}","gists_url":"https://api.github.com/users/ganga-devs/gists{/gist_id}","starred_url":"https://api.github.com/users/ganga-devs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ganga-devs/subscriptions","organizations_url":"https://api.github.com/users/ganga-devs/orgs","repos_url":"https://api.github.com/users/ganga-devs/repos","events_url":"https://api.github.com/users/ganga-devs/events{/privacy}","received_events_url":"https://api.github.com/users/ganga-devs/received_events","type":"Organization","site_admin":false},"repo":{"id":43645564,"name":"ganga","full_name":"ganga-devs/ganga","owner":{"login":"ganga-devs","id":13271048,"avatar_url":"https://avatars.githubusercontent.com/u/13271048?v=3","gravatar_id":"","url":"https://api.github.com/users/ganga-devs","html_url":"https://github.com/ganga-devs","followers_url":"https://api.github.com/users/ganga-devs/followers","following_url":"https://api.github.com/users/ganga-devs/following{/other_user}","gists_url":"https://api.github.com/users/ganga-devs/gists{/gist_id}","starred_url":"https://api.github.com/users/ganga-devs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ganga-devs/subscriptions","organizations_url":"https://api.github.com/users/ganga-devs/orgs","repos_url":"https://api.github.com/users/ganga-devs/repos","events_url":"https://api.github.com/users/ganga-devs/events{/privacy}","received_events_url":"https://api.github.com/users/ganga-devs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ganga-devs/ganga","description":"Ganga is an easy-to-use frontend for job definition and management","fork":false,"url":"https://api.github.com/repos/ganga-devs/ganga","forks_url":"https://api.github.com/repos/ganga-devs/ganga/forks","keys_url":"https://api.github.com/repos/ganga-devs/ganga/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ganga-devs/ganga/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ganga-devs/ganga/teams","hooks_url":"https://api.github.com/repos/ganga-devs/ganga/hooks","issue_events_url":"https://api.github.com/repos/ganga-devs/ganga/issues/events{/number}","events_url":"https://api.github.com/repos/ganga-devs/ganga/events","assignees_url":"https://api.github.com/repos/ganga-devs/ganga/assignees{/user}","branches_url":"https://api.github.com/repos/ganga-devs/ganga/branches{/branch}","tags_url":"https://api.github.com/repos/ganga-devs/ganga/tags","blobs_url":"https://api.github.com/repos/ganga-devs/ganga/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ganga-devs/ganga/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ganga-devs/ganga/git/refs{/sha}","trees_url":"https://api.github.com/repos/ganga-devs/ganga/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ganga-devs/ganga/statuses/{sha}","languages_url":"https://api.github.com/repos/ganga-devs/ganga/languages","stargazers_url":"https://api.github.com/repos/ganga-devs/ganga/stargazers","contributors_url":"https://api.github.com/repos/ganga-devs/ganga/contributors","subscribers_url":"https://api.github.com/repos/ganga-devs/ganga/subscribers","subscription_url":"https://api.github.com/repos/ganga-devs/ganga/subscription","commits_url":"https://api.github.com/repos/ganga-devs/ganga/commits{/sha}","git_commits_url":"https://api.github.com/repos/ganga-devs/ganga/git/commits{/sha}","comments_url":"https://api.github.com/repos/ganga-devs/ganga/comments{/number}","issue_comment_url":"https://api.github.com/repos/ganga-devs/ganga/issues/comments{/number}","contents_url":"https://api.github.com/repos/ganga-devs/ganga/contents/{+path}","compare_url":"https://api.github.com/repos/ganga-devs/ganga/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ganga-devs/ganga/merges","archive_url":"https://api.github.com/repos/ganga-devs/ganga/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ganga-devs/ganga/downloads","issues_url":"https://api.github.com/repos/ganga-devs/ganga/issues{/number}","pulls_url":"https://api.github.com/repos/ganga-devs/ganga/pulls{/number}","milestones_url":"https://api.github.com/repos/ganga-devs/ganga/milestones{/number}","notifications_url":"https://api.github.com/repos/ganga-devs/ganga/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ganga-devs/ganga/labels{/name}","releases_url":"https://api.github.com/repos/ganga-devs/ganga/releases{/id}","deployments_url":"https://api.github.com/repos/ganga-devs/ganga/deployments","created_at":"2015-10-04T17:39:11Z","updated_at":"2016-05-11T13:17:05Z","pushed_at":"2016-05-23T10:38:50Z","git_url":"git://github.com/ganga-devs/ganga.git","ssh_url":"git@github.com:ganga-devs/ganga.git","clone_url":"https://github.com/ganga-devs/ganga.git","svn_url":"https://github.com/ganga-devs/ganga","homepage":"https://cern.ch/ganga","size":28624,"stargazers_count":17,"watchers_count":17,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":11,"mirror_url":null,"open_issues_count":116,"forks":11,"open_issues":116,"watchers":17,"default_branch":"develop"}},"base":{"label":"ganga-devs:develop","ref":"develop","sha":"a45658318321913994101c3e8f0d5e9908fed341","user":{"login":"ganga-devs","id":13271048,"avatar_url":"https://avatars.githubusercontent.com/u/13271048?v=3","gravatar_id":"","url":"https://api.github.com/users/ganga-devs","html_url":"https://github.com/ganga-devs","followers_url":"https://api.github.com/users/ganga-devs/followers","following_url":"https://api.github.com/users/ganga-devs/following{/other_user}","gists_url":"https://api.github.com/users/ganga-devs/gists{/gist_id}","starred_url":"https://api.github.com/users/ganga-devs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ganga-devs/subscriptions","organizations_url":"https://api.github.com/users/ganga-devs/orgs","repos_url":"https://api.github.com/users/ganga-devs/repos","events_url":"https://api.github.com/users/ganga-devs/events{/privacy}","received_events_url":"https://api.github.com/users/ganga-devs/received_events","type":"Organization","site_admin":false},"repo":{"id":43645564,"name":"ganga","full_name":"ganga-devs/ganga","owner":{"login":"ganga-devs","id":13271048,"avatar_url":"https://avatars.githubusercontent.com/u/13271048?v=3","gravatar_id":"","url":"https://api.github.com/users/ganga-devs","html_url":"https://github.com/ganga-devs","followers_url":"https://api.github.com/users/ganga-devs/followers","following_url":"https://api.github.com/users/ganga-devs/following{/other_user}","gists_url":"https://api.github.com/users/ganga-devs/gists{/gist_id}","starred_url":"https://api.github.com/users/ganga-devs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ganga-devs/subscriptions","organizations_url":"https://api.github.com/users/ganga-devs/orgs","repos_url":"https://api.github.com/users/ganga-devs/repos","events_url":"https://api.github.com/users/ganga-devs/events{/privacy}","received_events_url":"https://api.github.com/users/ganga-devs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ganga-devs/ganga","description":"Ganga is an easy-to-use frontend for job definition and management","fork":false,"url":"https://api.github.com/repos/ganga-devs/ganga","forks_url":"https://api.github.com/repos/ganga-devs/ganga/forks","keys_url":"https://api.github.com/repos/ganga-devs/ganga/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ganga-devs/ganga/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ganga-devs/ganga/teams","hooks_url":"https://api.github.com/repos/ganga-devs/ganga/hooks","issue_events_url":"https://api.github.com/repos/ganga-devs/ganga/issues/events{/number}","events_url":"https://api.github.com/repos/ganga-devs/ganga/events","assignees_url":"https://api.github.com/repos/ganga-devs/ganga/assignees{/user}","branches_url":"https://api.github.com/repos/ganga-devs/ganga/branches{/branch}","tags_url":"https://api.github.com/repos/ganga-devs/ganga/tags","blobs_url":"https://api.github.com/repos/ganga-devs/ganga/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ganga-devs/ganga/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ganga-devs/ganga/git/refs{/sha}","trees_url":"https://api.github.com/repos/ganga-devs/ganga/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ganga-devs/ganga/statuses/{sha}","languages_url":"https://api.github.com/repos/ganga-devs/ganga/languages","stargazers_url":"https://api.github.com/repos/ganga-devs/ganga/stargazers","contributors_url":"https://api.github.com/repos/ganga-devs/ganga/contributors","subscribers_url":"https://api.github.com/repos/ganga-devs/ganga/subscribers","subscription_url":"https://api.github.com/repos/ganga-devs/ganga/subscription","commits_url":"https://api.github.com/repos/ganga-devs/ganga/commits{/sha}","git_commits_url":"https://api.github.com/repos/ganga-devs/ganga/git/commits{/sha}","comments_url":"https://api.github.com/repos/ganga-devs/ganga/comments{/number}","issue_comment_url":"https://api.github.com/repos/ganga-devs/ganga/issues/comments{/number}","contents_url":"https://api.github.com/repos/ganga-devs/ganga/contents/{+path}","compare_url":"https://api.github.com/repos/ganga-devs/ganga/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ganga-devs/ganga/merges","archive_url":"https://api.github.com/repos/ganga-devs/ganga/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ganga-devs/ganga/downloads","issues_url":"https://api.github.com/repos/ganga-devs/ganga/issues{/number}","pulls_url":"https://api.github.com/repos/ganga-devs/ganga/pulls{/number}","milestones_url":"https://api.github.com/repos/ganga-devs/ganga/milestones{/number}","notifications_url":"https://api.github.com/repos/ganga-devs/ganga/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ganga-devs/ganga/labels{/name}","releases_url":"https://api.github.com/repos/ganga-devs/ganga/releases{/id}","deployments_url":"https://api.github.com/repos/ganga-devs/ganga/deployments","created_at":"2015-10-04T17:39:11Z","updated_at":"2016-05-11T13:17:05Z","pushed_at":"2016-05-23T10:38:50Z","git_url":"git://github.com/ganga-devs/ganga.git","ssh_url":"git@github.com:ganga-devs/ganga.git","clone_url":"https://github.com/ganga-devs/ganga.git","svn_url":"https://github.com/ganga-devs/ganga","homepage":"https://cern.ch/ganga","size":28624,"stargazers_count":17,"watchers_count":17,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":11,"mirror_url":null,"open_issues_count":116,"forks":11,"open_issues":116,"watchers":17,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/507"},"html":{"href":"https://github.com/ganga-devs/ganga/pull/507"},"issue":{"href":"https://api.github.com/repos/ganga-devs/ganga/issues/507"},"comments":{"href":"https://api.github.com/repos/ganga-devs/ganga/issues/507/comments"},"review_comments":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/507/comments"},"review_comment":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ganga-devs/ganga/pulls/507/commits"},"statuses":{"href":"https://api.github.com/repos/ganga-devs/ganga/statuses/108254bf70dc117ea58840a7dafee74d1e1fdc0c"}}}}
{"actor":{"display_login":"milliams"}}