{"action":"created","comment":{"url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/comments/40599442","id":40599442,"diff_hunk":"@@ -42,8 +42,9 @@ def test_fulfillment_success(self):\n \n         # Validate the value of the HTTP Authorization header.\n         last_request = httpretty.last_request()\n-        authorization = last_request.headers.get('authorization')\n-        self.assertEqual(authorization, 'Bearer ' + get_configuration('WORKER_ACCESS_TOKEN'))\n+        authorization = last_request.headers.get('authorization').split()[1]","path":"ecommerce_worker/fulfillment/v1/tests/test_tasks.py","position":22,"original_position":22,"commit_id":"ca0f85564162cd52822046e521ffd7794f1f6a32","original_commit_id":"ca0f85564162cd52822046e521ffd7794f1f6a32","user":{"login":"rlucioni","id":969289,"avatar_url":"https://avatars.githubusercontent.com/u/969289?v=3","gravatar_id":"","url":"https://api.github.com/users/rlucioni","html_url":"https://github.com/rlucioni","followers_url":"https://api.github.com/users/rlucioni/followers","following_url":"https://api.github.com/users/rlucioni/following{/other_user}","gists_url":"https://api.github.com/users/rlucioni/gists{/gist_id}","starred_url":"https://api.github.com/users/rlucioni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlucioni/subscriptions","organizations_url":"https://api.github.com/users/rlucioni/orgs","repos_url":"https://api.github.com/users/rlucioni/repos","events_url":"https://api.github.com/users/rlucioni/events{/privacy}","received_events_url":"https://api.github.com/users/rlucioni/received_events","type":"User","site_admin":false},"body":"Nitpick: to help someone who's not familiar with the way this header is constructed understand what's going on here, consider naming this variable `token` instead of `authorization`. It no longer contains the complete authorization header, just the encoded token.","created_at":"2015-09-28T20:13:54Z","updated_at":"2015-09-28T20:13:54Z","html_url":"https://github.com/edx/ecommerce-worker/pull/4#discussion_r40599442","pull_request_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/comments/40599442"},"html":{"href":"https://github.com/edx/ecommerce-worker/pull/4#discussion_r40599442"},"pull_request":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4","id":46011254,"html_url":"https://github.com/edx/ecommerce-worker/pull/4","diff_url":"https://github.com/edx/ecommerce-worker/pull/4.diff","patch_url":"https://github.com/edx/ecommerce-worker/pull/4.patch","issue_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/4","number":4,"state":"open","locked":false,"title":"Enable authentication via JWT for ecommerce workers.","user":{"login":"peter-fogg","id":1819831,"avatar_url":"https://avatars.githubusercontent.com/u/1819831?v=3","gravatar_id":"","url":"https://api.github.com/users/peter-fogg","html_url":"https://github.com/peter-fogg","followers_url":"https://api.github.com/users/peter-fogg/followers","following_url":"https://api.github.com/users/peter-fogg/following{/other_user}","gists_url":"https://api.github.com/users/peter-fogg/gists{/gist_id}","starred_url":"https://api.github.com/users/peter-fogg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peter-fogg/subscriptions","organizations_url":"https://api.github.com/users/peter-fogg/orgs","repos_url":"https://api.github.com/users/peter-fogg/repos","events_url":"https://api.github.com/users/peter-fogg/events{/privacy}","received_events_url":"https://api.github.com/users/peter-fogg/received_events","type":"User","site_admin":false},"body":"The `fulfill_order` task is now passed the information to create a JWT to authenticate to the ecommerce service.\r\n\r\n@rlucioni @clintonb @bderusha @rock345 ","created_at":"2015-09-25T13:25:39Z","updated_at":"2015-09-28T20:13:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4b37620c303b4eb9bd88d12aa28bed0088c57877","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4/commits","review_comments_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4/comments","review_comment_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/4/comments","statuses_url":"https://api.github.com/repos/edx/ecommerce-worker/statuses/ca0f85564162cd52822046e521ffd7794f1f6a32","head":{"label":"edx:peter-fogg/worker-auth","ref":"peter-fogg/worker-auth","sha":"ca0f85564162cd52822046e521ffd7794f1f6a32","user":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"repo":{"id":42269790,"name":"ecommerce-worker","full_name":"edx/ecommerce-worker","owner":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/edx/ecommerce-worker","description":"","fork":false,"url":"https://api.github.com/repos/edx/ecommerce-worker","forks_url":"https://api.github.com/repos/edx/ecommerce-worker/forks","keys_url":"https://api.github.com/repos/edx/ecommerce-worker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/edx/ecommerce-worker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/edx/ecommerce-worker/teams","hooks_url":"https://api.github.com/repos/edx/ecommerce-worker/hooks","issue_events_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/events{/number}","events_url":"https://api.github.com/repos/edx/ecommerce-worker/events","assignees_url":"https://api.github.com/repos/edx/ecommerce-worker/assignees{/user}","branches_url":"https://api.github.com/repos/edx/ecommerce-worker/branches{/branch}","tags_url":"https://api.github.com/repos/edx/ecommerce-worker/tags","blobs_url":"https://api.github.com/repos/edx/ecommerce-worker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/edx/ecommerce-worker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/edx/ecommerce-worker/git/refs{/sha}","trees_url":"https://api.github.com/repos/edx/ecommerce-worker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/edx/ecommerce-worker/statuses/{sha}","languages_url":"https://api.github.com/repos/edx/ecommerce-worker/languages","stargazers_url":"https://api.github.com/repos/edx/ecommerce-worker/stargazers","contributors_url":"https://api.github.com/repos/edx/ecommerce-worker/contributors","subscribers_url":"https://api.github.com/repos/edx/ecommerce-worker/subscribers","subscription_url":"https://api.github.com/repos/edx/ecommerce-worker/subscription","commits_url":"https://api.github.com/repos/edx/ecommerce-worker/commits{/sha}","git_commits_url":"https://api.github.com/repos/edx/ecommerce-worker/git/commits{/sha}","comments_url":"https://api.github.com/repos/edx/ecommerce-worker/comments{/number}","issue_comment_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/comments{/number}","contents_url":"https://api.github.com/repos/edx/ecommerce-worker/contents/{+path}","compare_url":"https://api.github.com/repos/edx/ecommerce-worker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/edx/ecommerce-worker/merges","archive_url":"https://api.github.com/repos/edx/ecommerce-worker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/edx/ecommerce-worker/downloads","issues_url":"https://api.github.com/repos/edx/ecommerce-worker/issues{/number}","pulls_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls{/number}","milestones_url":"https://api.github.com/repos/edx/ecommerce-worker/milestones{/number}","notifications_url":"https://api.github.com/repos/edx/ecommerce-worker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/edx/ecommerce-worker/labels{/name}","releases_url":"https://api.github.com/repos/edx/ecommerce-worker/releases{/id}","created_at":"2015-09-10T20:45:12Z","updated_at":"2015-09-22T16:56:52Z","pushed_at":"2015-09-28T19:40:25Z","git_url":"git://github.com/edx/ecommerce-worker.git","ssh_url":"git@github.com:edx/ecommerce-worker.git","clone_url":"https://github.com/edx/ecommerce-worker.git","svn_url":"https://github.com/edx/ecommerce-worker","homepage":null,"size":304,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"edx:master","ref":"master","sha":"79da02fb2f60a8d3beeb0f9e927a1fec39895cf9","user":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"repo":{"id":42269790,"name":"ecommerce-worker","full_name":"edx/ecommerce-worker","owner":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/edx/ecommerce-worker","description":"","fork":false,"url":"https://api.github.com/repos/edx/ecommerce-worker","forks_url":"https://api.github.com/repos/edx/ecommerce-worker/forks","keys_url":"https://api.github.com/repos/edx/ecommerce-worker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/edx/ecommerce-worker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/edx/ecommerce-worker/teams","hooks_url":"https://api.github.com/repos/edx/ecommerce-worker/hooks","issue_events_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/events{/number}","events_url":"https://api.github.com/repos/edx/ecommerce-worker/events","assignees_url":"https://api.github.com/repos/edx/ecommerce-worker/assignees{/user}","branches_url":"https://api.github.com/repos/edx/ecommerce-worker/branches{/branch}","tags_url":"https://api.github.com/repos/edx/ecommerce-worker/tags","blobs_url":"https://api.github.com/repos/edx/ecommerce-worker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/edx/ecommerce-worker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/edx/ecommerce-worker/git/refs{/sha}","trees_url":"https://api.github.com/repos/edx/ecommerce-worker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/edx/ecommerce-worker/statuses/{sha}","languages_url":"https://api.github.com/repos/edx/ecommerce-worker/languages","stargazers_url":"https://api.github.com/repos/edx/ecommerce-worker/stargazers","contributors_url":"https://api.github.com/repos/edx/ecommerce-worker/contributors","subscribers_url":"https://api.github.com/repos/edx/ecommerce-worker/subscribers","subscription_url":"https://api.github.com/repos/edx/ecommerce-worker/subscription","commits_url":"https://api.github.com/repos/edx/ecommerce-worker/commits{/sha}","git_commits_url":"https://api.github.com/repos/edx/ecommerce-worker/git/commits{/sha}","comments_url":"https://api.github.com/repos/edx/ecommerce-worker/comments{/number}","issue_comment_url":"https://api.github.com/repos/edx/ecommerce-worker/issues/comments{/number}","contents_url":"https://api.github.com/repos/edx/ecommerce-worker/contents/{+path}","compare_url":"https://api.github.com/repos/edx/ecommerce-worker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/edx/ecommerce-worker/merges","archive_url":"https://api.github.com/repos/edx/ecommerce-worker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/edx/ecommerce-worker/downloads","issues_url":"https://api.github.com/repos/edx/ecommerce-worker/issues{/number}","pulls_url":"https://api.github.com/repos/edx/ecommerce-worker/pulls{/number}","milestones_url":"https://api.github.com/repos/edx/ecommerce-worker/milestones{/number}","notifications_url":"https://api.github.com/repos/edx/ecommerce-worker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/edx/ecommerce-worker/labels{/name}","releases_url":"https://api.github.com/repos/edx/ecommerce-worker/releases{/id}","created_at":"2015-09-10T20:45:12Z","updated_at":"2015-09-22T16:56:52Z","pushed_at":"2015-09-28T19:40:25Z","git_url":"git://github.com/edx/ecommerce-worker.git","ssh_url":"git@github.com:edx/ecommerce-worker.git","clone_url":"https://github.com/edx/ecommerce-worker.git","svn_url":"https://github.com/edx/ecommerce-worker","homepage":null,"size":304,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4"},"html":{"href":"https://github.com/edx/ecommerce-worker/pull/4"},"issue":{"href":"https://api.github.com/repos/edx/ecommerce-worker/issues/4"},"comments":{"href":"https://api.github.com/repos/edx/ecommerce-worker/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/edx/ecommerce-worker/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/edx/ecommerce-worker/statuses/ca0f85564162cd52822046e521ffd7794f1f6a32"}}}}