{"action":"closed","number":11,"pull_request":{"url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11","id":182842321,"html_url":"https://github.com/lvisintini/imperial-assault-data/pull/11","diff_url":"https://github.com/lvisintini/imperial-assault-data/pull/11.diff","patch_url":"https://github.com/lvisintini/imperial-assault-data/pull/11.patch","issue_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/11","number":11,"state":"closed","locked":false,"title":"Add cannonical names (iaspec)","user":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"body":"## Proposed iaspec change\r\n\r\n### Definition\r\n\r\n- Canonical names are unique across the whole dataset. (we could do away with this if it is problematic down the like, but for the moment it is easily achieved)\r\n- Canonical names only use alphanumerical characters in lower case (no spaces allowed)\r\n\r\n- To get a canonical name for a particular component, there are 4 strategies:\r\n    1. Use **elite** and **name** values\r\n    1. Use **elite**, **name** and **game mode** values.\r\n    1. Use **elite**, **name** and **affiliation** values.\r\n    1. Use **elite**, **name** and **description** values.\r\n\r\n- If an entry does not have a given value, or that values is `null` or `false`, don't add anything to the canonical name.\r\n- If an entry's value is set to `true`, then add that value's name to the canonical name, except in the case of *elite* (see below)\r\n- If an user has ``entry.elite == true``, only add `'elite'` to the canonical name if  ``entry.unique == false``\r\n- If a entry's value references an array of other elements, only add to the name if that array has only 1 element. Example: (Only add `'skirmish'` or `'campaign'` to the canonical name if `entry.modes.length == 1`)\r\n\r\n\r\n### Procedure\r\n\r\n1. You take all entries that are going to need canonical names (regardless of type) and you define canonical names as an empty string. (just to begin with, we will change)\r\n1. Run the strategies in ascending order and do the following:\r\n    1. You take all the entries that share the same canonical name and use the current strategy to get new canonical names\r\n    1. All the entries that do not have duplicates are taken out of this loop and no longer tampered with.\r\n    1. Go back to step 2.ii using the next strategy.\r\n1. If we continue to have duplicated canonical names, then this specification needs to further adapt to accommodate for the additional edge cases \r\n\r\nI have abstracted this in some code, but it is not the easiest to read at the moment.\r\n\r\n### Results\r\nUsing the above I'm able to match 93.53% of the canonical names currently in [iaskirmish-data](https://github.com/kingargyle/iaskirmish-data) (340 unique names)\r\n\r\nThis are the mismatches:\r\n\r\niaspec | proposed | notes\r\n------ | -------- | -----\r\nlukeskywalkerjedi | lukeskywalkerjediknight | Needs renaming to use the description/tag line\r\nlukeskywalker | lukeskywalkerherooftherebellion, lukeskywalkerjediknight | Needs desambiguation\r\nleiaorgana | leiaorganacampaign, leiaorganaskirmish | Needs desambiguation\r\nobiwankenobi | obiwankenobiskirmish, obiwankenobicampaign | Needs desambiguation\r\nr2d2 | r2d2campaign, r2d2skirmish | Needs desambiguation\r\nfuryofkashyyk | furyofkashyyyk | There is a typo in iaskirmish-data\r\natst | eliteatst | Needs to accomodate for the fact that there could be a regular variant\r\nsc2mrepulsortank | elitesc2mrepulsortank | Needs to accomodate for the fact that there could be a regular variant\r\natdp | eliteatdp | Needs to accomodate for the fact that there could be a regular variant\r\nagentblaise | agentblaisecampaign, agentblaiseskirmish | Needs desambiguation\r\ndewbackrider | elitedewbackrider | Needs to accomodate for the fact that there could be a regular variant\r\nriottrooper | riottroopercampaign, riottrooperskirmish, eliteriottroopercampaign, eliteriottrooperskirmish | Needs desambiguation\r\ncrosstraining | elitecrosstraining | Needs to accomodate for the fact that there could be a regular variant\r\ntemporaryallianceempire | temporaryalliancemercenary, temporaryallianceimperial | Needs renaming (Imperial deployment, Mercenary deployment, Rebel deployment)\r\nrancor | eliterancorcampaign, eliterancorskirmish | Needs to accomodate for the fact that there could be a regular variant\r\nbantharider | elitebantharider | Needs to accomodate for the fact that there could be a regular variant\r\nbossk | bosskmercenary, bosskrebel | Needs desambiguation\r\njabbathehutt | jabbathehuttcampaign, jabbathehuttskirmish | Needs desambiguation\r\nelitejawascavenger | jawascavenger, elitejawascavengercampaign, elitejawascavengerskirmish | Needs to accommodate for 3 versions\r\ntempoaryalliancescum | None | There is a typo in iaskirmish-data\r\nfeedingfrenzy | elitefeedingfrenzy |  Needs to accomodate for the fact that there could be a regular variant\r\nsarlacsweep | sarlaccsweep | There is a typo in iaskirmish-data","created_at":"2018-04-19T17:12:21Z","updated_at":"2018-04-24T14:58:54Z","closed_at":"2018-04-24T14:58:54Z","merged_at":"2018-04-24T14:58:53Z","merge_commit_sha":"656a0849a92704da17595c1997af511bbe69e13b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11/commits","review_comments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11/comments","review_comment_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/11/comments","statuses_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/statuses/947d5ee86cab8cff5c92811612bc74d359e46547","head":{"label":"lvisintini:canonical-names","ref":"canonical-names","sha":"947d5ee86cab8cff5c92811612bc74d359e46547","user":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"repo":{"id":121056091,"name":"imperial-assault-data","full_name":"lvisintini/imperial-assault-data","owner":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lvisintini/imperial-assault-data","description":"An easy-to-use collection of data and images from the Imperial Assault Game by Fantasy Flight Games.","fork":false,"url":"https://api.github.com/repos/lvisintini/imperial-assault-data","forks_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/forks","keys_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/teams","hooks_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/hooks","issue_events_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/events{/number}","events_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/events","assignees_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/assignees{/user}","branches_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/branches{/branch}","tags_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/tags","blobs_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/refs{/sha}","trees_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/statuses/{sha}","languages_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/languages","stargazers_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/stargazers","contributors_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/contributors","subscribers_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/subscribers","subscription_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/subscription","commits_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/commits{/sha}","git_commits_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/commits{/sha}","comments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/comments{/number}","issue_comment_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/comments{/number}","contents_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/contents/{+path}","compare_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/merges","archive_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/downloads","issues_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues{/number}","pulls_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls{/number}","milestones_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/milestones{/number}","notifications_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/labels{/name}","releases_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/releases{/id}","deployments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/deployments","created_at":"2018-02-10T21:31:52Z","updated_at":"2018-04-24T14:54:53Z","pushed_at":"2018-04-24T14:58:53Z","git_url":"git://github.com/lvisintini/imperial-assault-data.git","ssh_url":"git@github.com:lvisintini/imperial-assault-data.git","clone_url":"https://github.com/lvisintini/imperial-assault-data.git","svn_url":"https://github.com/lvisintini/imperial-assault-data","homepage":null,"size":409806,"stargazers_count":7,"watchers_count":7,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":0,"open_issues":6,"watchers":7,"default_branch":"master"}},"base":{"label":"lvisintini:master","ref":"master","sha":"19a85382f252ed61f55b9bdf7a540690c6a90c74","user":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"repo":{"id":121056091,"name":"imperial-assault-data","full_name":"lvisintini/imperial-assault-data","owner":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lvisintini/imperial-assault-data","description":"An easy-to-use collection of data and images from the Imperial Assault Game by Fantasy Flight Games.","fork":false,"url":"https://api.github.com/repos/lvisintini/imperial-assault-data","forks_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/forks","keys_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/teams","hooks_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/hooks","issue_events_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/events{/number}","events_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/events","assignees_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/assignees{/user}","branches_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/branches{/branch}","tags_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/tags","blobs_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/refs{/sha}","trees_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/statuses/{sha}","languages_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/languages","stargazers_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/stargazers","contributors_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/contributors","subscribers_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/subscribers","subscription_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/subscription","commits_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/commits{/sha}","git_commits_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/git/commits{/sha}","comments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/comments{/number}","issue_comment_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/comments{/number}","contents_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/contents/{+path}","compare_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/merges","archive_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/downloads","issues_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues{/number}","pulls_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls{/number}","milestones_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/milestones{/number}","notifications_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/labels{/name}","releases_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/releases{/id}","deployments_url":"https://api.github.com/repos/lvisintini/imperial-assault-data/deployments","created_at":"2018-02-10T21:31:52Z","updated_at":"2018-04-24T14:54:53Z","pushed_at":"2018-04-24T14:58:53Z","git_url":"git://github.com/lvisintini/imperial-assault-data.git","ssh_url":"git@github.com:lvisintini/imperial-assault-data.git","clone_url":"https://github.com/lvisintini/imperial-assault-data.git","svn_url":"https://github.com/lvisintini/imperial-assault-data","homepage":null,"size":409806,"stargazers_count":7,"watchers_count":7,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":0,"open_issues":6,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11"},"html":{"href":"https://github.com/lvisintini/imperial-assault-data/pull/11"},"issue":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/11"},"comments":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/lvisintini/imperial-assault-data/statuses/947d5ee86cab8cff5c92811612bc74d359e46547"}},"author_association":"OWNER","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"lvisintini","id":3267001,"avatar_url":"https://avatars0.githubusercontent.com/u/3267001?v=4","gravatar_id":"","url":"https://api.github.com/users/lvisintini","html_url":"https://github.com/lvisintini","followers_url":"https://api.github.com/users/lvisintini/followers","following_url":"https://api.github.com/users/lvisintini/following{/other_user}","gists_url":"https://api.github.com/users/lvisintini/gists{/gist_id}","starred_url":"https://api.github.com/users/lvisintini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lvisintini/subscriptions","organizations_url":"https://api.github.com/users/lvisintini/orgs","repos_url":"https://api.github.com/users/lvisintini/repos","events_url":"https://api.github.com/users/lvisintini/events{/privacy}","received_events_url":"https://api.github.com/users/lvisintini/received_events","type":"User","site_admin":false},"comments":4,"review_comments":0,"maintainer_can_modify":false,"commits":3,"additions":785,"deletions":378,"changed_files":8}}
{"actor":{"display_login":"lvisintini"}}