{"action":"created","comment":{"url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/comments/236053601","pull_request_review_id":178062091,"id":236053601,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNjA1MzYwMQ==","diff_hunk":"@@ -3894,56 +3900,97 @@ void Session::startUpTorrents()\n         ++resumedTorrentsCount;\n     };\n \n-    qDebug(\"Starting up torrents\");\n+    qDebug(\"Starting up torrents...\");\n     qDebug(\"Queue size: %d\", fastresumes.size());\n-    // Resume downloads\n-    QMap<int, TorrentResumeData> queuedResumeData;\n-    int nextQueuePosition = 1;\n-    int numOfRemappedFiles = 0;\n+\n     const QRegularExpression rx(QLatin1String(\"^([A-Fa-f0-9]{40})\\\\.fastresume$\"));\n-    foreach (const QString &fastresumeName, fastresumes) {\n-        const QRegularExpressionMatch rxMatch = rx.match(fastresumeName);\n-        if (!rxMatch.hasMatch()) continue;\n \n-        QString hash = rxMatch.captured(1);\n-        QString fastresumePath = resumeDataDir.absoluteFilePath(fastresumeName);\n-        QByteArray data;\n-        CreateTorrentParams torrentParams;\n-        MagnetUri magnetUri;\n-        int queuePosition;\n-        if (readFile(fastresumePath, data) && loadTorrentResumeData(data, torrentParams, queuePosition, magnetUri)) {\n-            if (queuePosition <= nextQueuePosition) {\n-                startupTorrent({ hash, magnetUri, torrentParams, data });\n-\n-                if (queuePosition == nextQueuePosition) {\n-                    ++nextQueuePosition;\n-                    while (queuedResumeData.contains(nextQueuePosition)) {\n-                        startupTorrent(queuedResumeData.take(nextQueuePosition));\n-                        ++nextQueuePosition;\n+    if (isQueueingSystemEnabled()) {\n+        QFile queueFile {resumeDataDir.absoluteFilePath(QLatin1String {\"queue\"})};\n+\n+        // TODO: Remove the deprecated code below at v4.2","path":"src/base/bittorrent/session.cpp","position":225,"original_position":193,"commit_id":"56f0a532a6e242bd8ee13c79d8be5f642fc25467","original_commit_id":"59eb595b650a0e446f98cda745c1716b50e6b1b6","user":{"login":"LordNyriox","id":3100578,"node_id":"MDQ6VXNlcjMxMDA1Nzg=","avatar_url":"https://avatars2.githubusercontent.com/u/3100578?v=4","gravatar_id":"","url":"https://api.github.com/users/LordNyriox","html_url":"https://github.com/LordNyriox","followers_url":"https://api.github.com/users/LordNyriox/followers","following_url":"https://api.github.com/users/LordNyriox/following{/other_user}","gists_url":"https://api.github.com/users/LordNyriox/gists{/gist_id}","starred_url":"https://api.github.com/users/LordNyriox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LordNyriox/subscriptions","organizations_url":"https://api.github.com/users/LordNyriox/orgs","repos_url":"https://api.github.com/users/LordNyriox/repos","events_url":"https://api.github.com/users/LordNyriox/events{/privacy}","received_events_url":"https://api.github.com/users/LordNyriox/received_events","type":"User","site_admin":false},"body":"@glassez:  \r\n\r\n>it isn't bug to mark it as \"FIXME\". \r\n\r\nNo, but the LGTM report **does** return code-comments prefixed with `FIXME:` as part of its \"alerts\". ","created_at":"2018-11-24T20:57:57Z","updated_at":"2018-11-24T20:57:57Z","html_url":"https://github.com/qbittorrent/qBittorrent/pull/9883#discussion_r236053601","pull_request_url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/comments/236053601"},"html":{"href":"https://github.com/qbittorrent/qBittorrent/pull/9883#discussion_r236053601"},"pull_request":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883"}},"in_reply_to_id":236031981},"pull_request":{"url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883","id":232218653,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMyMjE4NjUz","html_url":"https://github.com/qbittorrent/qBittorrent/pull/9883","diff_url":"https://github.com/qbittorrent/qBittorrent/pull/9883.diff","patch_url":"https://github.com/qbittorrent/qBittorrent/pull/9883.patch","issue_url":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/9883","number":9883,"state":"open","locked":false,"title":"Save torrents queue in separate file","user":{"login":"glassez","id":5063477,"node_id":"MDQ6VXNlcjUwNjM0Nzc=","avatar_url":"https://avatars3.githubusercontent.com/u/5063477?v=4","gravatar_id":"","url":"https://api.github.com/users/glassez","html_url":"https://github.com/glassez","followers_url":"https://api.github.com/users/glassez/followers","following_url":"https://api.github.com/users/glassez/following{/other_user}","gists_url":"https://api.github.com/users/glassez/gists{/gist_id}","starred_url":"https://api.github.com/users/glassez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glassez/subscriptions","organizations_url":"https://api.github.com/users/glassez/orgs","repos_url":"https://api.github.com/users/glassez/repos","events_url":"https://api.github.com/users/glassez/events{/privacy}","received_events_url":"https://api.github.com/users/glassez/received_events","type":"User","site_admin":false},"body":"See #9556 for explanation.\r\n\r\n1. It saves/restores queue when \"queuing\" is enabled (unlike existing code). Is it acceptable change?\r\n2. <del>When user disables \"queuing\" it just stops saving queue file. Should it remove/clear queue file?</del>","created_at":"2018-11-20T07:39:20Z","updated_at":"2018-11-24T20:57:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"16fcc7139c88aed1ad4001e34d5b4d37e6e2fb7c","assignee":null,"assignees":[],"requested_reviewers":[{"login":"sledgehammer999","id":273315,"node_id":"MDQ6VXNlcjI3MzMxNQ==","avatar_url":"https://avatars0.githubusercontent.com/u/273315?v=4","gravatar_id":"","url":"https://api.github.com/users/sledgehammer999","html_url":"https://github.com/sledgehammer999","followers_url":"https://api.github.com/users/sledgehammer999/followers","following_url":"https://api.github.com/users/sledgehammer999/following{/other_user}","gists_url":"https://api.github.com/users/sledgehammer999/gists{/gist_id}","starred_url":"https://api.github.com/users/sledgehammer999/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sledgehammer999/subscriptions","organizations_url":"https://api.github.com/users/sledgehammer999/orgs","repos_url":"https://api.github.com/users/sledgehammer999/repos","events_url":"https://api.github.com/users/sledgehammer999/events{/privacy}","received_events_url":"https://api.github.com/users/sledgehammer999/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":662470851,"node_id":"MDU6TGFiZWw2NjI0NzA4NTE=","url":"https://api.github.com/repos/qbittorrent/qBittorrent/labels/Core","name":"Core","color":"111111","default":false}],"milestone":{"url":"https://api.github.com/repos/qbittorrent/qBittorrent/milestones/50","html_url":"https://github.com/qbittorrent/qBittorrent/milestone/50","labels_url":"https://api.github.com/repos/qbittorrent/qBittorrent/milestones/50/labels","id":3829917,"node_id":"MDk6TWlsZXN0b25lMzgyOTkxNw==","number":50,"title":"4.1.5","description":"","creator":{"login":"sledgehammer999","id":273315,"node_id":"MDQ6VXNlcjI3MzMxNQ==","avatar_url":"https://avatars0.githubusercontent.com/u/273315?v=4","gravatar_id":"","url":"https://api.github.com/users/sledgehammer999","html_url":"https://github.com/sledgehammer999","followers_url":"https://api.github.com/users/sledgehammer999/followers","following_url":"https://api.github.com/users/sledgehammer999/following{/other_user}","gists_url":"https://api.github.com/users/sledgehammer999/gists{/gist_id}","starred_url":"https://api.github.com/users/sledgehammer999/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sledgehammer999/subscriptions","organizations_url":"https://api.github.com/users/sledgehammer999/orgs","repos_url":"https://api.github.com/users/sledgehammer999/repos","events_url":"https://api.github.com/users/sledgehammer999/events{/privacy}","received_events_url":"https://api.github.com/users/sledgehammer999/received_events","type":"User","site_admin":false},"open_issues":9,"closed_issues":3,"state":"open","created_at":"2018-11-19T01:39:23Z","updated_at":"2018-11-24T02:55:14Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883/commits","review_comments_url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883/comments","review_comment_url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/comments{/number}","comments_url":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/9883/comments","statuses_url":"https://api.github.com/repos/qbittorrent/qBittorrent/statuses/56f0a532a6e242bd8ee13c79d8be5f642fc25467","head":{"label":"glassez:queue","ref":"queue","sha":"56f0a532a6e242bd8ee13c79d8be5f642fc25467","user":{"login":"glassez","id":5063477,"node_id":"MDQ6VXNlcjUwNjM0Nzc=","avatar_url":"https://avatars3.githubusercontent.com/u/5063477?v=4","gravatar_id":"","url":"https://api.github.com/users/glassez","html_url":"https://github.com/glassez","followers_url":"https://api.github.com/users/glassez/followers","following_url":"https://api.github.com/users/glassez/following{/other_user}","gists_url":"https://api.github.com/users/glassez/gists{/gist_id}","starred_url":"https://api.github.com/users/glassez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glassez/subscriptions","organizations_url":"https://api.github.com/users/glassez/orgs","repos_url":"https://api.github.com/users/glassez/repos","events_url":"https://api.github.com/users/glassez/events{/privacy}","received_events_url":"https://api.github.com/users/glassez/received_events","type":"User","site_admin":false},"repo":{"id":11788320,"node_id":"MDEwOlJlcG9zaXRvcnkxMTc4ODMyMA==","name":"qBittorrent","full_name":"glassez/qBittorrent","private":false,"owner":{"login":"glassez","id":5063477,"node_id":"MDQ6VXNlcjUwNjM0Nzc=","avatar_url":"https://avatars3.githubusercontent.com/u/5063477?v=4","gravatar_id":"","url":"https://api.github.com/users/glassez","html_url":"https://github.com/glassez","followers_url":"https://api.github.com/users/glassez/followers","following_url":"https://api.github.com/users/glassez/following{/other_user}","gists_url":"https://api.github.com/users/glassez/gists{/gist_id}","starred_url":"https://api.github.com/users/glassez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glassez/subscriptions","organizations_url":"https://api.github.com/users/glassez/orgs","repos_url":"https://api.github.com/users/glassez/repos","events_url":"https://api.github.com/users/glassez/events{/privacy}","received_events_url":"https://api.github.com/users/glassez/received_events","type":"User","site_admin":false},"html_url":"https://github.com/glassez/qBittorrent","description":"qBittorrent BitTorrent client","fork":true,"url":"https://api.github.com/repos/glassez/qBittorrent","forks_url":"https://api.github.com/repos/glassez/qBittorrent/forks","keys_url":"https://api.github.com/repos/glassez/qBittorrent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/glassez/qBittorrent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/glassez/qBittorrent/teams","hooks_url":"https://api.github.com/repos/glassez/qBittorrent/hooks","issue_events_url":"https://api.github.com/repos/glassez/qBittorrent/issues/events{/number}","events_url":"https://api.github.com/repos/glassez/qBittorrent/events","assignees_url":"https://api.github.com/repos/glassez/qBittorrent/assignees{/user}","branches_url":"https://api.github.com/repos/glassez/qBittorrent/branches{/branch}","tags_url":"https://api.github.com/repos/glassez/qBittorrent/tags","blobs_url":"https://api.github.com/repos/glassez/qBittorrent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/glassez/qBittorrent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/glassez/qBittorrent/git/refs{/sha}","trees_url":"https://api.github.com/repos/glassez/qBittorrent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/glassez/qBittorrent/statuses/{sha}","languages_url":"https://api.github.com/repos/glassez/qBittorrent/languages","stargazers_url":"https://api.github.com/repos/glassez/qBittorrent/stargazers","contributors_url":"https://api.github.com/repos/glassez/qBittorrent/contributors","subscribers_url":"https://api.github.com/repos/glassez/qBittorrent/subscribers","subscription_url":"https://api.github.com/repos/glassez/qBittorrent/subscription","commits_url":"https://api.github.com/repos/glassez/qBittorrent/commits{/sha}","git_commits_url":"https://api.github.com/repos/glassez/qBittorrent/git/commits{/sha}","comments_url":"https://api.github.com/repos/glassez/qBittorrent/comments{/number}","issue_comment_url":"https://api.github.com/repos/glassez/qBittorrent/issues/comments{/number}","contents_url":"https://api.github.com/repos/glassez/qBittorrent/contents/{+path}","compare_url":"https://api.github.com/repos/glassez/qBittorrent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/glassez/qBittorrent/merges","archive_url":"https://api.github.com/repos/glassez/qBittorrent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/glassez/qBittorrent/downloads","issues_url":"https://api.github.com/repos/glassez/qBittorrent/issues{/number}","pulls_url":"https://api.github.com/repos/glassez/qBittorrent/pulls{/number}","milestones_url":"https://api.github.com/repos/glassez/qBittorrent/milestones{/number}","notifications_url":"https://api.github.com/repos/glassez/qBittorrent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/glassez/qBittorrent/labels{/name}","releases_url":"https://api.github.com/repos/glassez/qBittorrent/releases{/id}","deployments_url":"https://api.github.com/repos/glassez/qBittorrent/deployments","created_at":"2013-07-31T10:19:53Z","updated_at":"2018-11-02T16:31:38Z","pushed_at":"2018-11-24T18:02:15Z","git_url":"git://github.com/glassez/qBittorrent.git","ssh_url":"git@github.com:glassez/qBittorrent.git","clone_url":"https://github.com/glassez/qBittorrent.git","svn_url":"https://github.com/glassez/qBittorrent","homepage":"http://www.qbittorrent.org","size":152095,"stargazers_count":2,"watchers_count":2,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":2,"default_branch":"master"}},"base":{"label":"qbittorrent:master","ref":"master","sha":"45cfac6c00135b331f5fe782bf6c1b40d2423e1c","user":{"login":"qbittorrent","id":2131270,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxMzEyNzA=","avatar_url":"https://avatars2.githubusercontent.com/u/2131270?v=4","gravatar_id":"","url":"https://api.github.com/users/qbittorrent","html_url":"https://github.com/qbittorrent","followers_url":"https://api.github.com/users/qbittorrent/followers","following_url":"https://api.github.com/users/qbittorrent/following{/other_user}","gists_url":"https://api.github.com/users/qbittorrent/gists{/gist_id}","starred_url":"https://api.github.com/users/qbittorrent/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qbittorrent/subscriptions","organizations_url":"https://api.github.com/users/qbittorrent/orgs","repos_url":"https://api.github.com/users/qbittorrent/repos","events_url":"https://api.github.com/users/qbittorrent/events{/privacy}","received_events_url":"https://api.github.com/users/qbittorrent/received_events","type":"Organization","site_admin":false},"repo":{"id":3351871,"node_id":"MDEwOlJlcG9zaXRvcnkzMzUxODcx","name":"qBittorrent","full_name":"qbittorrent/qBittorrent","private":false,"owner":{"login":"qbittorrent","id":2131270,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxMzEyNzA=","avatar_url":"https://avatars2.githubusercontent.com/u/2131270?v=4","gravatar_id":"","url":"https://api.github.com/users/qbittorrent","html_url":"https://github.com/qbittorrent","followers_url":"https://api.github.com/users/qbittorrent/followers","following_url":"https://api.github.com/users/qbittorrent/following{/other_user}","gists_url":"https://api.github.com/users/qbittorrent/gists{/gist_id}","starred_url":"https://api.github.com/users/qbittorrent/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qbittorrent/subscriptions","organizations_url":"https://api.github.com/users/qbittorrent/orgs","repos_url":"https://api.github.com/users/qbittorrent/repos","events_url":"https://api.github.com/users/qbittorrent/events{/privacy}","received_events_url":"https://api.github.com/users/qbittorrent/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/qbittorrent/qBittorrent","description":"qBittorrent BitTorrent client","fork":false,"url":"https://api.github.com/repos/qbittorrent/qBittorrent","forks_url":"https://api.github.com/repos/qbittorrent/qBittorrent/forks","keys_url":"https://api.github.com/repos/qbittorrent/qBittorrent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/qbittorrent/qBittorrent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/qbittorrent/qBittorrent/teams","hooks_url":"https://api.github.com/repos/qbittorrent/qBittorrent/hooks","issue_events_url":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/events{/number}","events_url":"https://api.github.com/repos/qbittorrent/qBittorrent/events","assignees_url":"https://api.github.com/repos/qbittorrent/qBittorrent/assignees{/user}","branches_url":"https://api.github.com/repos/qbittorrent/qBittorrent/branches{/branch}","tags_url":"https://api.github.com/repos/qbittorrent/qBittorrent/tags","blobs_url":"https://api.github.com/repos/qbittorrent/qBittorrent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/qbittorrent/qBittorrent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/qbittorrent/qBittorrent/git/refs{/sha}","trees_url":"https://api.github.com/repos/qbittorrent/qBittorrent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/qbittorrent/qBittorrent/statuses/{sha}","languages_url":"https://api.github.com/repos/qbittorrent/qBittorrent/languages","stargazers_url":"https://api.github.com/repos/qbittorrent/qBittorrent/stargazers","contributors_url":"https://api.github.com/repos/qbittorrent/qBittorrent/contributors","subscribers_url":"https://api.github.com/repos/qbittorrent/qBittorrent/subscribers","subscription_url":"https://api.github.com/repos/qbittorrent/qBittorrent/subscription","commits_url":"https://api.github.com/repos/qbittorrent/qBittorrent/commits{/sha}","git_commits_url":"https://api.github.com/repos/qbittorrent/qBittorrent/git/commits{/sha}","comments_url":"https://api.github.com/repos/qbittorrent/qBittorrent/comments{/number}","issue_comment_url":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/comments{/number}","contents_url":"https://api.github.com/repos/qbittorrent/qBittorrent/contents/{+path}","compare_url":"https://api.github.com/repos/qbittorrent/qBittorrent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/qbittorrent/qBittorrent/merges","archive_url":"https://api.github.com/repos/qbittorrent/qBittorrent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/qbittorrent/qBittorrent/downloads","issues_url":"https://api.github.com/repos/qbittorrent/qBittorrent/issues{/number}","pulls_url":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls{/number}","milestones_url":"https://api.github.com/repos/qbittorrent/qBittorrent/milestones{/number}","notifications_url":"https://api.github.com/repos/qbittorrent/qBittorrent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/qbittorrent/qBittorrent/labels{/name}","releases_url":"https://api.github.com/repos/qbittorrent/qBittorrent/releases{/id}","deployments_url":"https://api.github.com/repos/qbittorrent/qBittorrent/deployments","created_at":"2012-02-04T09:37:46Z","updated_at":"2018-11-24T20:00:42Z","pushed_at":"2018-11-24T18:02:18Z","git_url":"git://github.com/qbittorrent/qBittorrent.git","ssh_url":"git@github.com:qbittorrent/qBittorrent.git","clone_url":"https://github.com/qbittorrent/qBittorrent.git","svn_url":"https://github.com/qbittorrent/qBittorrent","homepage":"https://www.qbittorrent.org","size":168476,"stargazers_count":5288,"watchers_count":5288,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":929,"mirror_url":null,"archived":false,"open_issues_count":2267,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":929,"open_issues":2267,"watchers":5288,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883"},"html":{"href":"https://github.com/qbittorrent/qBittorrent/pull/9883"},"issue":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/9883"},"comments":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/issues/9883/comments"},"review_comments":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883/comments"},"review_comment":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/pulls/9883/commits"},"statuses":{"href":"https://api.github.com/repos/qbittorrent/qBittorrent/statuses/56f0a532a6e242bd8ee13c79d8be5f642fc25467"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"LordNyriox"}}