GitHub PullRequestReviewCommentEvent at 2014-06-22 21:24:53
Repository: NzbDrone
Actor: markus101
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/comments/14056834","id":14056834,"diff_hunk":"@@ -0,0 +1,164 @@\n+﻿using System.Web;\n+using NLog;\n+using System;\n+using System.Collections.Generic;\n+using System.Linq;\n+using NzbDrone.Common.Serializer;\n+using System.Net;\n+using RestSharp;\n+\n+namespace NzbDrone.Core.Download.Clients.UTorrent\n+{\n+    public interface IUTorrentProxy\n+    {\n+        Int32 GetVersion(UTorrentSettings settings);\n+        Dictionary<String, String> GetConfig(UTorrentSettings settings);\n+        List<UTorrentTorrent> GetTorrents(UTorrentSettings settings);\n+        void AddTorrentFromUrl(String torrentUrl, UTorrentSettings settings);\n+        void RemoveTorrent(String hash, Boolean removeData, UTorrentSettings settings);\n+        void SetTorrentLabel(String hash, String label, UTorrentSettings settings);\n+    }\n+\n+    public class UTorrentProxy : IUTorrentProxy\n+    {\n+        private readonly Logger _logger;\n+\n+        public UTorrentProxy(Logger logger)\n+        {\n+            _logger = logger;\n+        }\n+\n+        public Int32 GetVersion(UTorrentSettings settings)\n+        {\n+            var arguments = new Dictionary<String, Object>();\n+            arguments.Add(\"action\", \"getsettings\");\n+\n+            var result = ProcessRequest(arguments, settings);\n+\n+            return result.Build;\n+        }\n+\n+        public Dictionary<String, String> GetConfig(UTorrentSettings settings)\n+        {\n+            var arguments = new Dictionary<String, Object>();\n+            arguments.Add(\"action\", \"getsettings\");\n+\n+            var result = ProcessRequest(arguments, settings);\n+\n+            var configuration = new Dictionary<String, String>();\n+\n+            foreach (var configItem in result.Settings)\n+            {\n+                configuration.Add(configItem[0], configItem[2]);\n+            }\n+\n+            return configuration;\n+        }\n+\n+        public List<UTorrentTorrent> GetTorrents(UTorrentSettings settings)\n+        {\n+            var result = this.GetTorrentStatus(settings);","path":"src/NzbDrone.Core/Download/Clients/uTorrent/UTorrentProxy.cs","position":60,"original_position":60,"commit_id":"236b9e0e9eb91e6ff9ddc4219360de9cf8e081c1","original_commit_id":"236b9e0e9eb91e6ff9ddc4219360de9cf8e081c1","user":{"login":"markus101","id":413544,"avatar_url":"https://avatars.githubusercontent.com/u/413544?","gravatar_id":"5c0ad5d37b0e056c921ff8959af506a3","url":"https://api.github.com/users/markus101","html_url":"https://github.com/markus101","followers_url":"https://api.github.com/users/markus101/followers","following_url":"https://api.github.com/users/markus101/following{/other_user}","gists_url":"https://api.github.com/users/markus101/gists{/gist_id}","starred_url":"https://api.github.com/users/markus101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/markus101/subscriptions","organizations_url":"https://api.github.com/users/markus101/orgs","repos_url":"https://api.github.com/users/markus101/repos","events_url":"https://api.github.com/users/markus101/events{/privacy}","received_events_url":"https://api.github.com/users/markus101/received_events","type":"User","site_admin":false},"body":"Remove this.","created_at":"2014-06-22T21:24:53Z","updated_at":"2014-06-22T21:24:53Z","html_url":"https://github.com/NzbDrone/NzbDrone/pull/76#discussion_r14056834","pull_request_url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76","_links":{"self":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/comments/14056834"},"html":{"href":"https://github.com/NzbDrone/NzbDrone/pull/76#discussion_r14056834"},"pull_request":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76"}}},"pull_request":{"url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76","id":15196939,"html_url":"https://github.com/NzbDrone/NzbDrone/pull/76","diff_url":"https://github.com/NzbDrone/NzbDrone/pull/76.diff","patch_url":"https://github.com/NzbDrone/NzbDrone/pull/76.patch","issue_url":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/76","number":76,"state":"open","title":"Collaboration on Torrent support","user":{"login":"Taloth","id":6383890,"avatar_url":"https://avatars.githubusercontent.com/u/6383890?","gravatar_id":"988111f29ffeec7da09809fa323f9568","url":"https://api.github.com/users/Taloth","html_url":"https://github.com/Taloth","followers_url":"https://api.github.com/users/Taloth/followers","following_url":"https://api.github.com/users/Taloth/following{/other_user}","gists_url":"https://api.github.com/users/Taloth/gists{/gist_id}","starred_url":"https://api.github.com/users/Taloth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Taloth/subscriptions","organizations_url":"https://api.github.com/users/Taloth/orgs","repos_url":"https://api.github.com/users/Taloth/repos","events_url":"https://api.github.com/users/Taloth/events{/privacy}","received_events_url":"https://api.github.com/users/Taloth/received_events","type":"User","site_admin":false},"body":"Most of the work was done by @mythjuha but it's based on the Completed Download Handling that has _finally_ been merged to develop.\r\n\r\nTorrent support integrates nicely with Completed Download Handling since seeding torrents are copied, instead of moved.\r\n\r\nPlease note that Transmission doesn't support labels, and as such Drone can only import downloads it grabbed explicitly. Unlike uTorrent & Deluge, in which you can add a download to the label and have drone pick it up once finished.\r\n\r\nAdditionally the GetStatus method on Transmission isn't implemented yet.","created_at":"2014-04-26T00:16:45Z","updated_at":"2014-06-22T21:24:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dab76903caf6a267503556b637f08da01f730347","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76/commits","review_comments_url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76/comments","review_comment_url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/comments/{number}","comments_url":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/76/comments","statuses_url":"https://api.github.com/repos/NzbDrone/NzbDrone/statuses/236b9e0e9eb91e6ff9ddc4219360de9cf8e081c1","head":{"label":"Taloth:torrent-collab","ref":"torrent-collab","sha":"236b9e0e9eb91e6ff9ddc4219360de9cf8e081c1","user":{"login":"Taloth","id":6383890,"avatar_url":"https://avatars.githubusercontent.com/u/6383890?","gravatar_id":"988111f29ffeec7da09809fa323f9568","url":"https://api.github.com/users/Taloth","html_url":"https://github.com/Taloth","followers_url":"https://api.github.com/users/Taloth/followers","following_url":"https://api.github.com/users/Taloth/following{/other_user}","gists_url":"https://api.github.com/users/Taloth/gists{/gist_id}","starred_url":"https://api.github.com/users/Taloth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Taloth/subscriptions","organizations_url":"https://api.github.com/users/Taloth/orgs","repos_url":"https://api.github.com/users/Taloth/repos","events_url":"https://api.github.com/users/Taloth/events{/privacy}","received_events_url":"https://api.github.com/users/Taloth/received_events","type":"User","site_admin":false},"repo":{"id":16023905,"name":"NzbDrone","full_name":"Taloth/NzbDrone","owner":{"login":"Taloth","id":6383890,"avatar_url":"https://avatars.githubusercontent.com/u/6383890?","gravatar_id":"988111f29ffeec7da09809fa323f9568","url":"https://api.github.com/users/Taloth","html_url":"https://github.com/Taloth","followers_url":"https://api.github.com/users/Taloth/followers","following_url":"https://api.github.com/users/Taloth/following{/other_user}","gists_url":"https://api.github.com/users/Taloth/gists{/gist_id}","starred_url":"https://api.github.com/users/Taloth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Taloth/subscriptions","organizations_url":"https://api.github.com/users/Taloth/orgs","repos_url":"https://api.github.com/users/Taloth/repos","events_url":"https://api.github.com/users/Taloth/events{/privacy}","received_events_url":"https://api.github.com/users/Taloth/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Taloth/NzbDrone","description":"Smart PVR for newsgroup users.","fork":true,"url":"https://api.github.com/repos/Taloth/NzbDrone","forks_url":"https://api.github.com/repos/Taloth/NzbDrone/forks","keys_url":"https://api.github.com/repos/Taloth/NzbDrone/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Taloth/NzbDrone/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Taloth/NzbDrone/teams","hooks_url":"https://api.github.com/repos/Taloth/NzbDrone/hooks","issue_events_url":"https://api.github.com/repos/Taloth/NzbDrone/issues/events{/number}","events_url":"https://api.github.com/repos/Taloth/NzbDrone/events","assignees_url":"https://api.github.com/repos/Taloth/NzbDrone/assignees{/user}","branches_url":"https://api.github.com/repos/Taloth/NzbDrone/branches{/branch}","tags_url":"https://api.github.com/repos/Taloth/NzbDrone/tags","blobs_url":"https://api.github.com/repos/Taloth/NzbDrone/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Taloth/NzbDrone/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Taloth/NzbDrone/git/refs{/sha}","trees_url":"https://api.github.com/repos/Taloth/NzbDrone/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Taloth/NzbDrone/statuses/{sha}","languages_url":"https://api.github.com/repos/Taloth/NzbDrone/languages","stargazers_url":"https://api.github.com/repos/Taloth/NzbDrone/stargazers","contributors_url":"https://api.github.com/repos/Taloth/NzbDrone/contributors","subscribers_url":"https://api.github.com/repos/Taloth/NzbDrone/subscribers","subscription_url":"https://api.github.com/repos/Taloth/NzbDrone/subscription","commits_url":"https://api.github.com/repos/Taloth/NzbDrone/commits{/sha}","git_commits_url":"https://api.github.com/repos/Taloth/NzbDrone/git/commits{/sha}","comments_url":"https://api.github.com/repos/Taloth/NzbDrone/comments{/number}","issue_comment_url":"https://api.github.com/repos/Taloth/NzbDrone/issues/comments/{number}","contents_url":"https://api.github.com/repos/Taloth/NzbDrone/contents/{+path}","compare_url":"https://api.github.com/repos/Taloth/NzbDrone/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Taloth/NzbDrone/merges","archive_url":"https://api.github.com/repos/Taloth/NzbDrone/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Taloth/NzbDrone/downloads","issues_url":"https://api.github.com/repos/Taloth/NzbDrone/issues{/number}","pulls_url":"https://api.github.com/repos/Taloth/NzbDrone/pulls{/number}","milestones_url":"https://api.github.com/repos/Taloth/NzbDrone/milestones{/number}","notifications_url":"https://api.github.com/repos/Taloth/NzbDrone/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Taloth/NzbDrone/labels{/name}","releases_url":"https://api.github.com/repos/Taloth/NzbDrone/releases{/id}","created_at":"2014-01-18T11:04:15Z","updated_at":"2014-06-22T19:51:23Z","pushed_at":"2014-06-22T19:51:23Z","git_url":"git://github.com/Taloth/NzbDrone.git","ssh_url":"git@github.com:Taloth/NzbDrone.git","clone_url":"https://github.com/Taloth/NzbDrone.git","svn_url":"https://github.com/Taloth/NzbDrone","homepage":"http://www.nzbdrone.com","size":181276,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"NzbDrone:develop","ref":"develop","sha":"590a39a47e27414c78ceb45336108563ae7d03bc","user":{"login":"NzbDrone","id":1082903,"avatar_url":"https://avatars.githubusercontent.com/u/1082903?","gravatar_id":"160c1e4dced76fe9490f003e30921d6c","url":"https://api.github.com/users/NzbDrone","html_url":"https://github.com/NzbDrone","followers_url":"https://api.github.com/users/NzbDrone/followers","following_url":"https://api.github.com/users/NzbDrone/following{/other_user}","gists_url":"https://api.github.com/users/NzbDrone/gists{/gist_id}","starred_url":"https://api.github.com/users/NzbDrone/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NzbDrone/subscriptions","organizations_url":"https://api.github.com/users/NzbDrone/orgs","repos_url":"https://api.github.com/users/NzbDrone/repos","events_url":"https://api.github.com/users/NzbDrone/events{/privacy}","received_events_url":"https://api.github.com/users/NzbDrone/received_events","type":"Organization","site_admin":false},"repo":{"id":2465723,"name":"NzbDrone","full_name":"NzbDrone/NzbDrone","owner":{"login":"NzbDrone","id":1082903,"avatar_url":"https://avatars.githubusercontent.com/u/1082903?","gravatar_id":"160c1e4dced76fe9490f003e30921d6c","url":"https://api.github.com/users/NzbDrone","html_url":"https://github.com/NzbDrone","followers_url":"https://api.github.com/users/NzbDrone/followers","following_url":"https://api.github.com/users/NzbDrone/following{/other_user}","gists_url":"https://api.github.com/users/NzbDrone/gists{/gist_id}","starred_url":"https://api.github.com/users/NzbDrone/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NzbDrone/subscriptions","organizations_url":"https://api.github.com/users/NzbDrone/orgs","repos_url":"https://api.github.com/users/NzbDrone/repos","events_url":"https://api.github.com/users/NzbDrone/events{/privacy}","received_events_url":"https://api.github.com/users/NzbDrone/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/NzbDrone/NzbDrone","description":"Smart PVR for newsgroup users.","fork":false,"url":"https://api.github.com/repos/NzbDrone/NzbDrone","forks_url":"https://api.github.com/repos/NzbDrone/NzbDrone/forks","keys_url":"https://api.github.com/repos/NzbDrone/NzbDrone/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NzbDrone/NzbDrone/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NzbDrone/NzbDrone/teams","hooks_url":"https://api.github.com/repos/NzbDrone/NzbDrone/hooks","issue_events_url":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/events{/number}","events_url":"https://api.github.com/repos/NzbDrone/NzbDrone/events","assignees_url":"https://api.github.com/repos/NzbDrone/NzbDrone/assignees{/user}","branches_url":"https://api.github.com/repos/NzbDrone/NzbDrone/branches{/branch}","tags_url":"https://api.github.com/repos/NzbDrone/NzbDrone/tags","blobs_url":"https://api.github.com/repos/NzbDrone/NzbDrone/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NzbDrone/NzbDrone/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NzbDrone/NzbDrone/git/refs{/sha}","trees_url":"https://api.github.com/repos/NzbDrone/NzbDrone/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NzbDrone/NzbDrone/statuses/{sha}","languages_url":"https://api.github.com/repos/NzbDrone/NzbDrone/languages","stargazers_url":"https://api.github.com/repos/NzbDrone/NzbDrone/stargazers","contributors_url":"https://api.github.com/repos/NzbDrone/NzbDrone/contributors","subscribers_url":"https://api.github.com/repos/NzbDrone/NzbDrone/subscribers","subscription_url":"https://api.github.com/repos/NzbDrone/NzbDrone/subscription","commits_url":"https://api.github.com/repos/NzbDrone/NzbDrone/commits{/sha}","git_commits_url":"https://api.github.com/repos/NzbDrone/NzbDrone/git/commits{/sha}","comments_url":"https://api.github.com/repos/NzbDrone/NzbDrone/comments{/number}","issue_comment_url":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/comments/{number}","contents_url":"https://api.github.com/repos/NzbDrone/NzbDrone/contents/{+path}","compare_url":"https://api.github.com/repos/NzbDrone/NzbDrone/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NzbDrone/NzbDrone/merges","archive_url":"https://api.github.com/repos/NzbDrone/NzbDrone/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NzbDrone/NzbDrone/downloads","issues_url":"https://api.github.com/repos/NzbDrone/NzbDrone/issues{/number}","pulls_url":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls{/number}","milestones_url":"https://api.github.com/repos/NzbDrone/NzbDrone/milestones{/number}","notifications_url":"https://api.github.com/repos/NzbDrone/NzbDrone/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NzbDrone/NzbDrone/labels{/name}","releases_url":"https://api.github.com/repos/NzbDrone/NzbDrone/releases{/id}","created_at":"2011-09-27T05:57:16Z","updated_at":"2014-06-22T20:01:43Z","pushed_at":"2014-06-22T20:01:42Z","git_url":"git://github.com/NzbDrone/NzbDrone.git","ssh_url":"git@github.com:NzbDrone/NzbDrone.git","clone_url":"https://github.com/NzbDrone/NzbDrone.git","svn_url":"https://github.com/NzbDrone/NzbDrone","homepage":"http://www.nzbdrone.com","size":196858,"stargazers_count":176,"watchers_count":176,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"forks_count":60,"mirror_url":null,"open_issues_count":4,"forks":60,"open_issues":4,"watchers":176,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76"},"html":{"href":"https://github.com/NzbDrone/NzbDrone/pull/76"},"issue":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/76"},"comments":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/issues/76/comments"},"review_comments":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76/comments"},"review_comment":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/pulls/76/commits"},"statuses":{"href":"https://api.github.com/repos/NzbDrone/NzbDrone/statuses/236b9e0e9eb91e6ff9ddc4219360de9cf8e081c1"}}}}