{"action":"created","comment":{"url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments/71064822","id":71064822,"diff_hunk":"@@ -0,0 +1,15 @@\n+from __future__ import absolute_import, division, print_function, unicode_literals\n+\n+from gratipay.testing import Harness\n+\n+\n+class Tests(Harness):\n+\n+    def test_distributing_redirects_when_no_money_is_available(self):\n+        self.make_team()\n+        assert self.client.GxT('/TheEnterprise/distributing/').code == 302\n+\n+    def test_distributing_doesnt_redirect_when_money_is_available(self):\n+        self.make_team()\n+        self.db.run(\"UPDATE teams SET available=537\")\n+        assert self.client.GET('/TheEnterprise/distributing/', raise_immediately=False).code == 500","path":"tests/py/test_www_team_distributing.py","position":15,"original_position":15,"commit_id":"5db876012019103f9a46d4076f36f4e188616bea","original_commit_id":"5db876012019103f9a46d4076f36f4e188616bea","user":{"login":"whit537","id":134455,"avatar_url":"https://avatars.githubusercontent.com/u/134455?v=3","gravatar_id":"","url":"https://api.github.com/users/whit537","html_url":"https://github.com/whit537","followers_url":"https://api.github.com/users/whit537/followers","following_url":"https://api.github.com/users/whit537/following{/other_user}","gists_url":"https://api.github.com/users/whit537/gists{/gist_id}","starred_url":"https://api.github.com/users/whit537/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/whit537/subscriptions","organizations_url":"https://api.github.com/users/whit537/orgs","repos_url":"https://api.github.com/users/whit537/repos","events_url":"https://api.github.com/users/whit537/events{/privacy}","received_events_url":"https://api.github.com/users/whit537/received_events","type":"User","site_admin":false},"body":"It's a 500 that no user would've hit, since it's behind a flag (`available`) which no Team has the power to set themselves—making this PR deployable while also keeping it reasonably sized. However, this PR landed on master [together](https://github.com/gratipay/gratipay.com/issues/3994#issuecomment-232237350) with the next one (#4073), which includes a fix for the 500 (17b9bd37de4a9b088b8d4cd4732943cc9bf28d21). Now, #4073 *also* introduces a test for [_another_ 500](https://github.com/gratipay/gratipay.com/commit/4cfd33f33c51f81a9defa06a4513b5a4b978f1cf#diff-bdbc0e30f418dad4e477decfc410f9d1R35), which is [still](https://github.com/gratipay/gratipay.com/blob/1976/tests/py/test_www_team_distributing.py#L32-L35) on `master`. Again, my [thinking](https://github.com/gratipay/gratipay.com/issues/3994#issuecomment-229949952) is that deploying broken code behind the `available` flag allows us to keep chipping away with manageable PRs instead of batching up until everything is \"perfect.\" You okay with that?","created_at":"2016-07-16T11:22:15Z","updated_at":"2016-07-16T11:22:15Z","html_url":"https://github.com/gratipay/gratipay.com/pull/4072#discussion_r71064822","pull_request_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072","_links":{"self":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments/71064822"},"html":{"href":"https://github.com/gratipay/gratipay.com/pull/4072#discussion_r71064822"},"pull_request":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072"}}},"pull_request":{"url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072","id":75992658,"html_url":"https://github.com/gratipay/gratipay.com/pull/4072","diff_url":"https://github.com/gratipay/gratipay.com/pull/4072.diff","patch_url":"https://github.com/gratipay/gratipay.com/pull/4072.patch","issue_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/4072","number":4072,"state":"closed","locked":false,"title":"Bring back the payouts UI behind a flag","user":{"login":"whit537","id":134455,"avatar_url":"https://avatars.githubusercontent.com/u/134455?v=3","gravatar_id":"","url":"https://api.github.com/users/whit537","html_url":"https://github.com/whit537","followers_url":"https://api.github.com/users/whit537/followers","following_url":"https://api.github.com/users/whit537/following{/other_user}","gists_url":"https://api.github.com/users/whit537/gists{/gist_id}","starred_url":"https://api.github.com/users/whit537/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/whit537/subscriptions","organizations_url":"https://api.github.com/users/whit537/orgs","repos_url":"https://api.github.com/users/whit537/repos","events_url":"https://api.github.com/users/whit537/events{/privacy}","received_events_url":"https://api.github.com/users/whit537/received_events","type":"User","site_admin":false},"body":"&#x2B11; #3994\r\n\r\n&larr; #4070 ([diff](https://github.com/gratipay/gratipay.com/compare/docs-source-order...available)) — #4073 &rarr;\r\n\r\nSee https://github.com/gratipay/gratipay.com/issues/3994#issuecomment-229949952.\r\n\r\n- [ ] rebase after #4070 lands","created_at":"2016-07-01T14:57:48Z","updated_at":"2016-07-16T11:22:15Z","closed_at":"2016-07-13T02:25:17Z","merged_at":"2016-07-13T02:25:17Z","merge_commit_sha":"5db876012019103f9a46d4076f36f4e188616bea","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/gratipay/gratipay.com/milestones/14","html_url":"https://github.com/gratipay/gratipay.com/milestones/Bring%20Back%20Take-What-You-Want%20for%20Team%20Gratipay","labels_url":"https://api.github.com/repos/gratipay/gratipay.com/milestones/14/labels","id":1152632,"number":14,"title":"Bring Back Take-What-You-Want for Team Gratipay","description":"","creator":{"login":"whit537","id":134455,"avatar_url":"https://avatars.githubusercontent.com/u/134455?v=3","gravatar_id":"","url":"https://api.github.com/users/whit537","html_url":"https://github.com/whit537","followers_url":"https://api.github.com/users/whit537/followers","following_url":"https://api.github.com/users/whit537/following{/other_user}","gists_url":"https://api.github.com/users/whit537/gists{/gist_id}","starred_url":"https://api.github.com/users/whit537/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/whit537/subscriptions","organizations_url":"https://api.github.com/users/whit537/orgs","repos_url":"https://api.github.com/users/whit537/repos","events_url":"https://api.github.com/users/whit537/events{/privacy}","received_events_url":"https://api.github.com/users/whit537/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":47,"state":"open","created_at":"2015-06-06T12:30:18Z","updated_at":"2016-07-13T02:25:18Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072/commits","review_comments_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072/comments","review_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/4072/comments","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/5db876012019103f9a46d4076f36f4e188616bea","head":{"label":"gratipay:available","ref":"available","sha":"5db876012019103f9a46d4076f36f4e188616bea","user":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"repo":{"id":4521463,"name":"gratipay.com","full_name":"gratipay/gratipay.com","owner":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gratipay/gratipay.com","description":"Payments and Payouts for Open Work","fork":false,"url":"https://api.github.com/repos/gratipay/gratipay.com","forks_url":"https://api.github.com/repos/gratipay/gratipay.com/forks","keys_url":"https://api.github.com/repos/gratipay/gratipay.com/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gratipay/gratipay.com/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gratipay/gratipay.com/teams","hooks_url":"https://api.github.com/repos/gratipay/gratipay.com/hooks","issue_events_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/events{/number}","events_url":"https://api.github.com/repos/gratipay/gratipay.com/events","assignees_url":"https://api.github.com/repos/gratipay/gratipay.com/assignees{/user}","branches_url":"https://api.github.com/repos/gratipay/gratipay.com/branches{/branch}","tags_url":"https://api.github.com/repos/gratipay/gratipay.com/tags","blobs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gratipay/gratipay.com/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/refs{/sha}","trees_url":"https://api.github.com/repos/gratipay/gratipay.com/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/{sha}","languages_url":"https://api.github.com/repos/gratipay/gratipay.com/languages","stargazers_url":"https://api.github.com/repos/gratipay/gratipay.com/stargazers","contributors_url":"https://api.github.com/repos/gratipay/gratipay.com/contributors","subscribers_url":"https://api.github.com/repos/gratipay/gratipay.com/subscribers","subscription_url":"https://api.github.com/repos/gratipay/gratipay.com/subscription","commits_url":"https://api.github.com/repos/gratipay/gratipay.com/commits{/sha}","git_commits_url":"https://api.github.com/repos/gratipay/gratipay.com/git/commits{/sha}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/comments{/number}","issue_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/comments{/number}","contents_url":"https://api.github.com/repos/gratipay/gratipay.com/contents/{+path}","compare_url":"https://api.github.com/repos/gratipay/gratipay.com/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gratipay/gratipay.com/merges","archive_url":"https://api.github.com/repos/gratipay/gratipay.com/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gratipay/gratipay.com/downloads","issues_url":"https://api.github.com/repos/gratipay/gratipay.com/issues{/number}","pulls_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls{/number}","milestones_url":"https://api.github.com/repos/gratipay/gratipay.com/milestones{/number}","notifications_url":"https://api.github.com/repos/gratipay/gratipay.com/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gratipay/gratipay.com/labels{/name}","releases_url":"https://api.github.com/repos/gratipay/gratipay.com/releases{/id}","deployments_url":"https://api.github.com/repos/gratipay/gratipay.com/deployments","created_at":"2012-06-01T16:01:02Z","updated_at":"2016-07-16T04:03:19Z","pushed_at":"2016-07-14T21:38:39Z","git_url":"git://github.com/gratipay/gratipay.com.git","ssh_url":"git@github.com:gratipay/gratipay.com.git","clone_url":"https://github.com/gratipay/gratipay.com.git","svn_url":"https://github.com/gratipay/gratipay.com","homepage":"https://gratipay.com/","size":76265,"stargazers_count":946,"watchers_count":946,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":300,"mirror_url":null,"open_issues_count":437,"forks":300,"open_issues":437,"watchers":946,"default_branch":"master"}},"base":{"label":"gratipay:master","ref":"master","sha":"dcc69fd6a25f222636b97eb1a66d44c053f8f3d0","user":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"repo":{"id":4521463,"name":"gratipay.com","full_name":"gratipay/gratipay.com","owner":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gratipay/gratipay.com","description":"Payments and Payouts for Open Work","fork":false,"url":"https://api.github.com/repos/gratipay/gratipay.com","forks_url":"https://api.github.com/repos/gratipay/gratipay.com/forks","keys_url":"https://api.github.com/repos/gratipay/gratipay.com/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gratipay/gratipay.com/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gratipay/gratipay.com/teams","hooks_url":"https://api.github.com/repos/gratipay/gratipay.com/hooks","issue_events_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/events{/number}","events_url":"https://api.github.com/repos/gratipay/gratipay.com/events","assignees_url":"https://api.github.com/repos/gratipay/gratipay.com/assignees{/user}","branches_url":"https://api.github.com/repos/gratipay/gratipay.com/branches{/branch}","tags_url":"https://api.github.com/repos/gratipay/gratipay.com/tags","blobs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gratipay/gratipay.com/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/refs{/sha}","trees_url":"https://api.github.com/repos/gratipay/gratipay.com/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/{sha}","languages_url":"https://api.github.com/repos/gratipay/gratipay.com/languages","stargazers_url":"https://api.github.com/repos/gratipay/gratipay.com/stargazers","contributors_url":"https://api.github.com/repos/gratipay/gratipay.com/contributors","subscribers_url":"https://api.github.com/repos/gratipay/gratipay.com/subscribers","subscription_url":"https://api.github.com/repos/gratipay/gratipay.com/subscription","commits_url":"https://api.github.com/repos/gratipay/gratipay.com/commits{/sha}","git_commits_url":"https://api.github.com/repos/gratipay/gratipay.com/git/commits{/sha}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/comments{/number}","issue_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/comments{/number}","contents_url":"https://api.github.com/repos/gratipay/gratipay.com/contents/{+path}","compare_url":"https://api.github.com/repos/gratipay/gratipay.com/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gratipay/gratipay.com/merges","archive_url":"https://api.github.com/repos/gratipay/gratipay.com/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gratipay/gratipay.com/downloads","issues_url":"https://api.github.com/repos/gratipay/gratipay.com/issues{/number}","pulls_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls{/number}","milestones_url":"https://api.github.com/repos/gratipay/gratipay.com/milestones{/number}","notifications_url":"https://api.github.com/repos/gratipay/gratipay.com/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gratipay/gratipay.com/labels{/name}","releases_url":"https://api.github.com/repos/gratipay/gratipay.com/releases{/id}","deployments_url":"https://api.github.com/repos/gratipay/gratipay.com/deployments","created_at":"2012-06-01T16:01:02Z","updated_at":"2016-07-16T04:03:19Z","pushed_at":"2016-07-14T21:38:39Z","git_url":"git://github.com/gratipay/gratipay.com.git","ssh_url":"git@github.com:gratipay/gratipay.com.git","clone_url":"https://github.com/gratipay/gratipay.com.git","svn_url":"https://github.com/gratipay/gratipay.com","homepage":"https://gratipay.com/","size":76265,"stargazers_count":946,"watchers_count":946,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":300,"mirror_url":null,"open_issues_count":437,"forks":300,"open_issues":437,"watchers":946,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072"},"html":{"href":"https://github.com/gratipay/gratipay.com/pull/4072"},"issue":{"href":"https://api.github.com/repos/gratipay/gratipay.com/issues/4072"},"comments":{"href":"https://api.github.com/repos/gratipay/gratipay.com/issues/4072/comments"},"review_comments":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072/comments"},"review_comment":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/4072/commits"},"statuses":{"href":"https://api.github.com/repos/gratipay/gratipay.com/statuses/5db876012019103f9a46d4076f36f4e188616bea"}}}}
{"actor":{"display_login":"whit537"}}