{"action":"created","issue":{"url":"https://api.github.com/repos/sampsyo/beets/issues/1462","labels_url":"https://api.github.com/repos/sampsyo/beets/issues/1462/labels{/name}","comments_url":"https://api.github.com/repos/sampsyo/beets/issues/1462/comments","events_url":"https://api.github.com/repos/sampsyo/beets/issues/1462/events","html_url":"https://github.com/sampsyo/beets/pull/1462","id":77410956,"number":1462,"title":"Review request: add merging functionality to duplicates plugin","user":{"login":"pedros","id":253571,"avatar_url":"https://avatars.githubusercontent.com/u/253571?v=3","gravatar_id":"","url":"https://api.github.com/users/pedros","html_url":"https://github.com/pedros","followers_url":"https://api.github.com/users/pedros/followers","following_url":"https://api.github.com/users/pedros/following{/other_user}","gists_url":"https://api.github.com/users/pedros/gists{/gist_id}","starred_url":"https://api.github.com/users/pedros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pedros/subscriptions","organizations_url":"https://api.github.com/users/pedros/orgs","repos_url":"https://api.github.com/users/pedros/repos","events_url":"https://api.github.com/users/pedros/events{/privacy}","received_events_url":"https://api.github.com/users/pedros/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-17T22:09:28Z","updated_at":"2015-05-18T08:14:02Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/sampsyo/beets/pulls/1462","html_url":"https://github.com/sampsyo/beets/pull/1462","diff_url":"https://github.com/sampsyo/beets/pull/1462.diff","patch_url":"https://github.com/sampsyo/beets/pull/1462.patch"},"body":"This patch is based on the ordering imposed by the tiebreaking facility\r\nintroduced in 6be98b0a369aa148acee8906d55076ac824b5108. Once a natural\r\nduplicate ordering is in place, then the strategies for merging are:\r\n\r\nItems\r\n-----\r\n\r\n    Iterate through each available field:\r\n        Iterate through each duplicate:\r\n            If current duplicate has a field not set in the original, set it there\r\n            Break\r\n\r\nThis is, I believe, solved.\r\n\r\nAlbums\r\n------\r\n\r\n    Iterate through each duplicate:\r\n        Iterate through each item in duplicate:\r\n            If current item is not present in original, copy it there\r\n            Continue\r\n\r\nProblems:\r\n\r\nWhat to use to check for identical items in the album merging logic:\r\ncurrently I use mb_trackid; this is bound to break later on, or possibly\r\nright away on some libraries that don't use musicbrainz, or have items\r\nwith not musicbrainz IDs.\r\n\r\nI also don't completely understand how to cleanly move an item to a\r\ndifferent album.\r\n\r\nQuestions, comments, solutions welcome!"},"comment":{"url":"https://api.github.com/repos/sampsyo/beets/issues/comments/102963844","html_url":"https://github.com/sampsyo/beets/pull/1462#issuecomment-102963844","issue_url":"https://api.github.com/repos/sampsyo/beets/issues/1462","id":102963844,"user":{"login":"pedros","id":253571,"avatar_url":"https://avatars.githubusercontent.com/u/253571?v=3","gravatar_id":"","url":"https://api.github.com/users/pedros","html_url":"https://github.com/pedros","followers_url":"https://api.github.com/users/pedros/followers","following_url":"https://api.github.com/users/pedros/following{/other_user}","gists_url":"https://api.github.com/users/pedros/gists{/gist_id}","starred_url":"https://api.github.com/users/pedros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pedros/subscriptions","organizations_url":"https://api.github.com/users/pedros/orgs","repos_url":"https://api.github.com/users/pedros/repos","events_url":"https://api.github.com/users/pedros/events{/privacy}","received_events_url":"https://api.github.com/users/pedros/received_events","type":"User","site_admin":false},"created_at":"2015-05-18T08:14:02Z","updated_at":"2015-05-18T08:14:02Z","body":"I'm not sure what is going on with the build fails. They appear to have started with a commit prior to mine. Everything builds cleanly on my machine..."}}