{"action":"created","comment":{"url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/comments/74399597","id":74399597,"diff_hunk":"@@ -731,28 +732,49 @@ def set_command(self, win_id, section_=None, option=None, value=None,\n             print_ = True\n         else:\n             with self._handle_config_error():\n-                if option.endswith('!') and option != '!' and value is None:\n+                if option.endswith('!') and option != '!' and len(values) == 0:\n+                    # Handle inversion as special cases of the cycle code path\n                     option = option[:-1]\n                     val = self.get(section_, option)\n-                    layer = 'temp' if temp else 'conf'\n                     if isinstance(val, bool):\n-                        self.set(layer, section_, option, str(not val).lower())\n+                        values = ('false', 'true')\n                     else:\n                         raise cmdexc.CommandError(\n                             \"set: Attempted inversion of non-boolean value.\")\n-                elif value is not None:\n-                    layer = 'temp' if temp else 'conf'\n-                    self.set(layer, section_, option, value)\n-                else:\n+                elif len(values) == 0:","path":"qutebrowser/config/config.py","position":50,"original_position":50,"commit_id":"b22690641989582333d54fd0b2f7145871434808","original_commit_id":"b22690641989582333d54fd0b2f7145871434808","user":{"login":"The-Compiler","id":625793,"avatar_url":"https://avatars.githubusercontent.com/u/625793?v=3","gravatar_id":"","url":"https://api.github.com/users/The-Compiler","html_url":"https://github.com/The-Compiler","followers_url":"https://api.github.com/users/The-Compiler/followers","following_url":"https://api.github.com/users/The-Compiler/following{/other_user}","gists_url":"https://api.github.com/users/The-Compiler/gists{/gist_id}","starred_url":"https://api.github.com/users/The-Compiler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/The-Compiler/subscriptions","organizations_url":"https://api.github.com/users/The-Compiler/orgs","repos_url":"https://api.github.com/users/The-Compiler/repos","events_url":"https://api.github.com/users/The-Compiler/events{/privacy}","received_events_url":"https://api.github.com/users/The-Compiler/received_events","type":"User","site_admin":false},"body":"`elif not values:`","created_at":"2016-08-11T10:30:48Z","updated_at":"2016-08-11T10:30:48Z","html_url":"https://github.com/The-Compiler/qutebrowser/pull/1840#discussion_r74399597","pull_request_url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840","_links":{"self":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/comments/74399597"},"html":{"href":"https://github.com/The-Compiler/qutebrowser/pull/1840#discussion_r74399597"},"pull_request":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840"}}},"pull_request":{"url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840","id":80897689,"html_url":"https://github.com/The-Compiler/qutebrowser/pull/1840","diff_url":"https://github.com/The-Compiler/qutebrowser/pull/1840.diff","patch_url":"https://github.com/The-Compiler/qutebrowser/pull/1840.patch","issue_url":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/1840","number":1840,"state":"open","locked":false,"title":"Add a :set --cycle flag","user":{"login":"haasn","id":1149047,"avatar_url":"https://avatars.githubusercontent.com/u/1149047?v=3","gravatar_id":"","url":"https://api.github.com/users/haasn","html_url":"https://github.com/haasn","followers_url":"https://api.github.com/users/haasn/followers","following_url":"https://api.github.com/users/haasn/following{/other_user}","gists_url":"https://api.github.com/users/haasn/gists{/gist_id}","starred_url":"https://api.github.com/users/haasn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haasn/subscriptions","organizations_url":"https://api.github.com/users/haasn/orgs","repos_url":"https://api.github.com/users/haasn/repos","events_url":"https://api.github.com/users/haasn/events{/privacy}","received_events_url":"https://api.github.com/users/haasn/received_events","type":"User","site_admin":false},"body":"I'm not so sure about the second commit, I feel like there must be an easier way to do this.\r\n\r\nThat code in general seems fairly prone to breakage and subtle bugs such as differences between how the completer and the actual command execution decide to map parts to arguments.\r\n\r\nI'd love to add the ability to add some test cases for making sure the completer shows the right type of completion at any point as I type a command. (Maybe something could be hacked together with set-cmd-text and waiting for the completion messages to show up?)","created_at":"2016-08-11T02:44:02Z","updated_at":"2016-08-11T10:30:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"edaf9a83e7866c11e875af23146e198397bc0431","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840/commits","review_comments_url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840/comments","review_comment_url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/comments{/number}","comments_url":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/1840/comments","statuses_url":"https://api.github.com/repos/The-Compiler/qutebrowser/statuses/b22690641989582333d54fd0b2f7145871434808","head":{"label":"haasn:cycle","ref":"cycle","sha":"b22690641989582333d54fd0b2f7145871434808","user":{"login":"haasn","id":1149047,"avatar_url":"https://avatars.githubusercontent.com/u/1149047?v=3","gravatar_id":"","url":"https://api.github.com/users/haasn","html_url":"https://github.com/haasn","followers_url":"https://api.github.com/users/haasn/followers","following_url":"https://api.github.com/users/haasn/following{/other_user}","gists_url":"https://api.github.com/users/haasn/gists{/gist_id}","starred_url":"https://api.github.com/users/haasn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haasn/subscriptions","organizations_url":"https://api.github.com/users/haasn/orgs","repos_url":"https://api.github.com/users/haasn/repos","events_url":"https://api.github.com/users/haasn/events{/privacy}","received_events_url":"https://api.github.com/users/haasn/received_events","type":"User","site_admin":false},"repo":{"id":65213566,"name":"qutebrowser","full_name":"haasn/qutebrowser","owner":{"login":"haasn","id":1149047,"avatar_url":"https://avatars.githubusercontent.com/u/1149047?v=3","gravatar_id":"","url":"https://api.github.com/users/haasn","html_url":"https://github.com/haasn","followers_url":"https://api.github.com/users/haasn/followers","following_url":"https://api.github.com/users/haasn/following{/other_user}","gists_url":"https://api.github.com/users/haasn/gists{/gist_id}","starred_url":"https://api.github.com/users/haasn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haasn/subscriptions","organizations_url":"https://api.github.com/users/haasn/orgs","repos_url":"https://api.github.com/users/haasn/repos","events_url":"https://api.github.com/users/haasn/events{/privacy}","received_events_url":"https://api.github.com/users/haasn/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/haasn/qutebrowser","description":"A keyboard-driven, vim-like browser based on PyQt5.","fork":true,"url":"https://api.github.com/repos/haasn/qutebrowser","forks_url":"https://api.github.com/repos/haasn/qutebrowser/forks","keys_url":"https://api.github.com/repos/haasn/qutebrowser/keys{/key_id}","collaborators_url":"https://api.github.com/repos/haasn/qutebrowser/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/haasn/qutebrowser/teams","hooks_url":"https://api.github.com/repos/haasn/qutebrowser/hooks","issue_events_url":"https://api.github.com/repos/haasn/qutebrowser/issues/events{/number}","events_url":"https://api.github.com/repos/haasn/qutebrowser/events","assignees_url":"https://api.github.com/repos/haasn/qutebrowser/assignees{/user}","branches_url":"https://api.github.com/repos/haasn/qutebrowser/branches{/branch}","tags_url":"https://api.github.com/repos/haasn/qutebrowser/tags","blobs_url":"https://api.github.com/repos/haasn/qutebrowser/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/haasn/qutebrowser/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/haasn/qutebrowser/git/refs{/sha}","trees_url":"https://api.github.com/repos/haasn/qutebrowser/git/trees{/sha}","statuses_url":"https://api.github.com/repos/haasn/qutebrowser/statuses/{sha}","languages_url":"https://api.github.com/repos/haasn/qutebrowser/languages","stargazers_url":"https://api.github.com/repos/haasn/qutebrowser/stargazers","contributors_url":"https://api.github.com/repos/haasn/qutebrowser/contributors","subscribers_url":"https://api.github.com/repos/haasn/qutebrowser/subscribers","subscription_url":"https://api.github.com/repos/haasn/qutebrowser/subscription","commits_url":"https://api.github.com/repos/haasn/qutebrowser/commits{/sha}","git_commits_url":"https://api.github.com/repos/haasn/qutebrowser/git/commits{/sha}","comments_url":"https://api.github.com/repos/haasn/qutebrowser/comments{/number}","issue_comment_url":"https://api.github.com/repos/haasn/qutebrowser/issues/comments{/number}","contents_url":"https://api.github.com/repos/haasn/qutebrowser/contents/{+path}","compare_url":"https://api.github.com/repos/haasn/qutebrowser/compare/{base}...{head}","merges_url":"https://api.github.com/repos/haasn/qutebrowser/merges","archive_url":"https://api.github.com/repos/haasn/qutebrowser/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/haasn/qutebrowser/downloads","issues_url":"https://api.github.com/repos/haasn/qutebrowser/issues{/number}","pulls_url":"https://api.github.com/repos/haasn/qutebrowser/pulls{/number}","milestones_url":"https://api.github.com/repos/haasn/qutebrowser/milestones{/number}","notifications_url":"https://api.github.com/repos/haasn/qutebrowser/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/haasn/qutebrowser/labels{/name}","releases_url":"https://api.github.com/repos/haasn/qutebrowser/releases{/id}","deployments_url":"https://api.github.com/repos/haasn/qutebrowser/deployments","created_at":"2016-08-08T14:58:56Z","updated_at":"2016-08-08T14:58:59Z","pushed_at":"2016-08-11T05:34:48Z","git_url":"git://github.com/haasn/qutebrowser.git","ssh_url":"git@github.com:haasn/qutebrowser.git","clone_url":"https://github.com/haasn/qutebrowser.git","svn_url":"https://github.com/haasn/qutebrowser","homepage":"https://www.qutebrowser.org/","size":19185,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"The-Compiler:master","ref":"master","sha":"4a14ab5c06c1973158cdcf2c6db304cf95256fd0","user":{"login":"The-Compiler","id":625793,"avatar_url":"https://avatars.githubusercontent.com/u/625793?v=3","gravatar_id":"","url":"https://api.github.com/users/The-Compiler","html_url":"https://github.com/The-Compiler","followers_url":"https://api.github.com/users/The-Compiler/followers","following_url":"https://api.github.com/users/The-Compiler/following{/other_user}","gists_url":"https://api.github.com/users/The-Compiler/gists{/gist_id}","starred_url":"https://api.github.com/users/The-Compiler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/The-Compiler/subscriptions","organizations_url":"https://api.github.com/users/The-Compiler/orgs","repos_url":"https://api.github.com/users/The-Compiler/repos","events_url":"https://api.github.com/users/The-Compiler/events{/privacy}","received_events_url":"https://api.github.com/users/The-Compiler/received_events","type":"User","site_admin":false},"repo":{"id":21244505,"name":"qutebrowser","full_name":"The-Compiler/qutebrowser","owner":{"login":"The-Compiler","id":625793,"avatar_url":"https://avatars.githubusercontent.com/u/625793?v=3","gravatar_id":"","url":"https://api.github.com/users/The-Compiler","html_url":"https://github.com/The-Compiler","followers_url":"https://api.github.com/users/The-Compiler/followers","following_url":"https://api.github.com/users/The-Compiler/following{/other_user}","gists_url":"https://api.github.com/users/The-Compiler/gists{/gist_id}","starred_url":"https://api.github.com/users/The-Compiler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/The-Compiler/subscriptions","organizations_url":"https://api.github.com/users/The-Compiler/orgs","repos_url":"https://api.github.com/users/The-Compiler/repos","events_url":"https://api.github.com/users/The-Compiler/events{/privacy}","received_events_url":"https://api.github.com/users/The-Compiler/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/The-Compiler/qutebrowser","description":"A keyboard-driven, vim-like browser based on PyQt5.","fork":false,"url":"https://api.github.com/repos/The-Compiler/qutebrowser","forks_url":"https://api.github.com/repos/The-Compiler/qutebrowser/forks","keys_url":"https://api.github.com/repos/The-Compiler/qutebrowser/keys{/key_id}","collaborators_url":"https://api.github.com/repos/The-Compiler/qutebrowser/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/The-Compiler/qutebrowser/teams","hooks_url":"https://api.github.com/repos/The-Compiler/qutebrowser/hooks","issue_events_url":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/events{/number}","events_url":"https://api.github.com/repos/The-Compiler/qutebrowser/events","assignees_url":"https://api.github.com/repos/The-Compiler/qutebrowser/assignees{/user}","branches_url":"https://api.github.com/repos/The-Compiler/qutebrowser/branches{/branch}","tags_url":"https://api.github.com/repos/The-Compiler/qutebrowser/tags","blobs_url":"https://api.github.com/repos/The-Compiler/qutebrowser/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/The-Compiler/qutebrowser/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/The-Compiler/qutebrowser/git/refs{/sha}","trees_url":"https://api.github.com/repos/The-Compiler/qutebrowser/git/trees{/sha}","statuses_url":"https://api.github.com/repos/The-Compiler/qutebrowser/statuses/{sha}","languages_url":"https://api.github.com/repos/The-Compiler/qutebrowser/languages","stargazers_url":"https://api.github.com/repos/The-Compiler/qutebrowser/stargazers","contributors_url":"https://api.github.com/repos/The-Compiler/qutebrowser/contributors","subscribers_url":"https://api.github.com/repos/The-Compiler/qutebrowser/subscribers","subscription_url":"https://api.github.com/repos/The-Compiler/qutebrowser/subscription","commits_url":"https://api.github.com/repos/The-Compiler/qutebrowser/commits{/sha}","git_commits_url":"https://api.github.com/repos/The-Compiler/qutebrowser/git/commits{/sha}","comments_url":"https://api.github.com/repos/The-Compiler/qutebrowser/comments{/number}","issue_comment_url":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/comments{/number}","contents_url":"https://api.github.com/repos/The-Compiler/qutebrowser/contents/{+path}","compare_url":"https://api.github.com/repos/The-Compiler/qutebrowser/compare/{base}...{head}","merges_url":"https://api.github.com/repos/The-Compiler/qutebrowser/merges","archive_url":"https://api.github.com/repos/The-Compiler/qutebrowser/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/The-Compiler/qutebrowser/downloads","issues_url":"https://api.github.com/repos/The-Compiler/qutebrowser/issues{/number}","pulls_url":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls{/number}","milestones_url":"https://api.github.com/repos/The-Compiler/qutebrowser/milestones{/number}","notifications_url":"https://api.github.com/repos/The-Compiler/qutebrowser/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/The-Compiler/qutebrowser/labels{/name}","releases_url":"https://api.github.com/repos/The-Compiler/qutebrowser/releases{/id}","deployments_url":"https://api.github.com/repos/The-Compiler/qutebrowser/deployments","created_at":"2014-06-26T14:59:34Z","updated_at":"2016-08-11T03:07:02Z","pushed_at":"2016-08-11T09:58:40Z","git_url":"git://github.com/The-Compiler/qutebrowser.git","ssh_url":"git@github.com:The-Compiler/qutebrowser.git","clone_url":"https://github.com/The-Compiler/qutebrowser.git","svn_url":"https://github.com/The-Compiler/qutebrowser","homepage":"https://www.qutebrowser.org/","size":22969,"stargazers_count":1407,"watchers_count":1407,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":214,"mirror_url":null,"open_issues_count":413,"forks":214,"open_issues":413,"watchers":1407,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840"},"html":{"href":"https://github.com/The-Compiler/qutebrowser/pull/1840"},"issue":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/1840"},"comments":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/issues/1840/comments"},"review_comments":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840/comments"},"review_comment":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/pulls/1840/commits"},"statuses":{"href":"https://api.github.com/repos/The-Compiler/qutebrowser/statuses/b22690641989582333d54fd0b2f7145871434808"}}}}
{"actor":{"display_login":"The-Compiler"}}