{"action":"created","issue":{"url":"https://api.github.com/repos/praw-dev/praw/issues/455","labels_url":"https://api.github.com/repos/praw-dev/praw/issues/455/labels{/name}","comments_url":"https://api.github.com/repos/praw-dev/praw/issues/455/comments","events_url":"https://api.github.com/repos/praw-dev/praw/issues/455/events","html_url":"https://github.com/praw-dev/praw/pull/455","id":93945874,"number":455,"title":"08 July 2015 - Fix multi-scope methods; add leave_moderator","user":{"login":"voussoir","id":7299570,"avatar_url":"https://avatars.githubusercontent.com/u/7299570?v=3","gravatar_id":"","url":"https://api.github.com/users/voussoir","html_url":"https://github.com/voussoir","followers_url":"https://api.github.com/users/voussoir/followers","following_url":"https://api.github.com/users/voussoir/following{/other_user}","gists_url":"https://api.github.com/users/voussoir/gists{/gist_id}","starred_url":"https://api.github.com/users/voussoir/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/voussoir/subscriptions","organizations_url":"https://api.github.com/users/voussoir/orgs","repos_url":"https://api.github.com/users/voussoir/repos","events_url":"https://api.github.com/users/voussoir/events{/privacy}","received_events_url":"https://api.github.com/users/voussoir/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-09T03:40:29Z","updated_at":"2015-07-09T05:05:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/praw-dev/praw/pulls/455","html_url":"https://github.com/praw-dev/praw/pull/455","diff_url":"https://github.com/praw-dev/praw/pull/455.diff","patch_url":"https://github.com/praw-dev/praw/pull/455.patch"},"body":"Changes\r\n- Add support for multiple-scope methods by using lists for has_scope check\r\n- Use above to fix `add_wiki_ban` and `add_wiki_contributor`\r\n- Add `[modcontributors, modwiki]` relationship scope for above\r\n- Add `modcontributors` relationship scope as seen in #451\r\n- Fix `WikiPage.remove_editor` raising an AssertionError when using OAuth\r\n- Add refresh key and tests for `modwiki`\r\n- Add refresh key and tests for `modwiki+wikicontributors`\r\n\r\nConcerns\r\n- You'll notice that `test_scope_modwiki` shows me first loading the `wikiread` scope. This is required to perform `subreddit.get_wiki_page`, else it 403s. I would consider this a bug / shortcoming, because it means we're implicitly adding a scope dependency that isn't required by reddit. I'm not sure why `modwiki` doesn't allow you to load the page in the first place.\r\n\r\n- I'm debating whether I should add a leading underscore to `leave_status`. On one hand, the user shouldn't be calling it directly, they should use leave_moderator. On the other hand, this method has all of the docstring info, so I feel it shouldn't be privatized. I mean, privatizing doesn't stop them from reading it, it's just a formatting thing.\r\n\r\n&nbsp;\r\n\r\nNotes\r\n- The leave_moderator method had to go through a few evolutions to get to where it is now. Many of the reddit forms accept `{'r': 'reddit_api_test'}`, but leavemoderator and leavecontributor insist on requiring the subreddit's fullname. I tried everything to add this method to either the relationships section or the `_methods` section, but in the end I had to make it separate.\r\n\r\nCritique."},"comment":{"url":"https://api.github.com/repos/praw-dev/praw/issues/comments/119820172","html_url":"https://github.com/praw-dev/praw/pull/455#issuecomment-119820172","issue_url":"https://api.github.com/repos/praw-dev/praw/issues/455","id":119820172,"user":{"login":"voussoir","id":7299570,"avatar_url":"https://avatars.githubusercontent.com/u/7299570?v=3","gravatar_id":"","url":"https://api.github.com/users/voussoir","html_url":"https://github.com/voussoir","followers_url":"https://api.github.com/users/voussoir/followers","following_url":"https://api.github.com/users/voussoir/following{/other_user}","gists_url":"https://api.github.com/users/voussoir/gists{/gist_id}","starred_url":"https://api.github.com/users/voussoir/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/voussoir/subscriptions","organizations_url":"https://api.github.com/users/voussoir/orgs","repos_url":"https://api.github.com/users/voussoir/repos","events_url":"https://api.github.com/users/voussoir/events{/privacy}","received_events_url":"https://api.github.com/users/voussoir/received_events","type":"User","site_admin":false},"created_at":"2015-07-09T05:05:06Z","updated_at":"2015-07-09T05:05:06Z","body":">Can we make this private\r\n\r\nAlright, no problem. Extra docstrings added.\r\n\r\n&nbsp;\r\n\r\n> I don't think we're adding any dependencies.\r\n\r\nNo, we certainly are. Here I am bypassing it:\r\n\r\n![image](https://cloud.githubusercontent.com/assets/7299570/8588183/a9682bb4-25bb-11e5-935f-dcf145fd514c.png)\r\n\r\n![image](https://cloud.githubusercontent.com/assets/7299570/8588197/cac98730-25bb-11e5-87ca-79cd30de2a96.png)\r\n\r\n>Getting pages simply requires a different scope\r\n\r\nThis is true, but `add_editor` isn't supposed to get the page, it's supposed to add an editor -- no wikiread required for that. Personally I don't consider this the highest of priorities, but it's worth noting."}}