{"action":"created","comment":{"url":"https://api.github.com/repos/unitedstack/gringotts/pulls/comments/65831402","id":65831402,"diff_hunk":"@@ -119,13 +119,14 @@ def get_unit_price(self, env, body, method):\n                                            collection.service,\n                                            collection.region_id)\n         if product:\n-            if 'extra' in product:\n-                price_data = pricing.get_price_data(product['extra'], method)\n+            if 'unit_price' in product:\n+                price_data = pricing.get_price_data(product['unit_price'],\n+                                                    method)\n             else:\n                 price_data = None\n \n             return pricing.calculate_price(\n-                collection.resource_volume, product['unit_price'], price_data)\n+                collection.resource_volume, None, price_data)","path":"gringotts/middleware/base.py","position":14,"original_position":14,"commit_id":"da5790790c42bd39468398d36b1f311ef8e9f458","original_commit_id":"da5790790c42bd39468398d36b1f311ef8e9f458","user":{"login":"hackerain","id":2007096,"avatar_url":"https://avatars.githubusercontent.com/u/2007096?v=3","gravatar_id":"","url":"https://api.github.com/users/hackerain","html_url":"https://github.com/hackerain","followers_url":"https://api.github.com/users/hackerain/followers","following_url":"https://api.github.com/users/hackerain/following{/other_user}","gists_url":"https://api.github.com/users/hackerain/gists{/gist_id}","starred_url":"https://api.github.com/users/hackerain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hackerain/subscriptions","organizations_url":"https://api.github.com/users/hackerain/orgs","repos_url":"https://api.github.com/users/hackerain/repos","events_url":"https://api.github.com/users/hackerain/events{/privacy}","received_events_url":"https://api.github.com/users/hackerain/received_events","type":"User","site_admin":false},"body":"改一下calculate_price这个接口，把unit_price去掉","created_at":"2016-06-06T02:15:09Z","updated_at":"2016-06-06T02:15:09Z","html_url":"https://github.com/unitedstack/gringotts/pull/1#discussion_r65831402","pull_request_url":"https://api.github.com/repos/unitedstack/gringotts/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/comments/65831402"},"html":{"href":"https://github.com/unitedstack/gringotts/pull/1#discussion_r65831402"},"pull_request":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/unitedstack/gringotts/pulls/1","id":72317337,"html_url":"https://github.com/unitedstack/gringotts/pull/1","diff_url":"https://github.com/unitedstack/gringotts/pull/1.diff","patch_url":"https://github.com/unitedstack/gringotts/pull/1.patch","issue_url":"https://api.github.com/repos/unitedstack/gringotts/issues/1","number":1,"state":"open","locked":false,"title":"Add create, delete and resize logic into middleware for hourly billing","user":{"login":"ShooterTT","id":5717967,"avatar_url":"https://avatars.githubusercontent.com/u/5717967?v=3","gravatar_id":"","url":"https://api.github.com/users/ShooterTT","html_url":"https://github.com/ShooterTT","followers_url":"https://api.github.com/users/ShooterTT/followers","following_url":"https://api.github.com/users/ShooterTT/following{/other_user}","gists_url":"https://api.github.com/users/ShooterTT/gists{/gist_id}","starred_url":"https://api.github.com/users/ShooterTT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ShooterTT/subscriptions","organizations_url":"https://api.github.com/users/ShooterTT/orgs","repos_url":"https://api.github.com/users/ShooterTT/repos","events_url":"https://api.github.com/users/ShooterTT/events{/privacy}","received_events_url":"https://api.github.com/users/ShooterTT/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-02T09:47:10Z","updated_at":"2016-06-06T02:15:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bef5518d139714315855e7955276d86d86cb13e1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/unitedstack/gringotts/pulls/1/commits","review_comments_url":"https://api.github.com/repos/unitedstack/gringotts/pulls/1/comments","review_comment_url":"https://api.github.com/repos/unitedstack/gringotts/pulls/comments{/number}","comments_url":"https://api.github.com/repos/unitedstack/gringotts/issues/1/comments","statuses_url":"https://api.github.com/repos/unitedstack/gringotts/statuses/da5790790c42bd39468398d36b1f311ef8e9f458","head":{"label":"ShooterTT:hour","ref":"hour","sha":"da5790790c42bd39468398d36b1f311ef8e9f458","user":{"login":"ShooterTT","id":5717967,"avatar_url":"https://avatars.githubusercontent.com/u/5717967?v=3","gravatar_id":"","url":"https://api.github.com/users/ShooterTT","html_url":"https://github.com/ShooterTT","followers_url":"https://api.github.com/users/ShooterTT/followers","following_url":"https://api.github.com/users/ShooterTT/following{/other_user}","gists_url":"https://api.github.com/users/ShooterTT/gists{/gist_id}","starred_url":"https://api.github.com/users/ShooterTT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ShooterTT/subscriptions","organizations_url":"https://api.github.com/users/ShooterTT/orgs","repos_url":"https://api.github.com/users/ShooterTT/repos","events_url":"https://api.github.com/users/ShooterTT/events{/privacy}","received_events_url":"https://api.github.com/users/ShooterTT/received_events","type":"User","site_admin":false},"repo":{"id":59545990,"name":"gringotts","full_name":"ShooterTT/gringotts","owner":{"login":"ShooterTT","id":5717967,"avatar_url":"https://avatars.githubusercontent.com/u/5717967?v=3","gravatar_id":"","url":"https://api.github.com/users/ShooterTT","html_url":"https://github.com/ShooterTT","followers_url":"https://api.github.com/users/ShooterTT/followers","following_url":"https://api.github.com/users/ShooterTT/following{/other_user}","gists_url":"https://api.github.com/users/ShooterTT/gists{/gist_id}","starred_url":"https://api.github.com/users/ShooterTT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ShooterTT/subscriptions","organizations_url":"https://api.github.com/users/ShooterTT/orgs","repos_url":"https://api.github.com/users/ShooterTT/repos","events_url":"https://api.github.com/users/ShooterTT/events{/privacy}","received_events_url":"https://api.github.com/users/ShooterTT/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ShooterTT/gringotts","description":"A billing service for OpenStack","fork":true,"url":"https://api.github.com/repos/ShooterTT/gringotts","forks_url":"https://api.github.com/repos/ShooterTT/gringotts/forks","keys_url":"https://api.github.com/repos/ShooterTT/gringotts/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ShooterTT/gringotts/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ShooterTT/gringotts/teams","hooks_url":"https://api.github.com/repos/ShooterTT/gringotts/hooks","issue_events_url":"https://api.github.com/repos/ShooterTT/gringotts/issues/events{/number}","events_url":"https://api.github.com/repos/ShooterTT/gringotts/events","assignees_url":"https://api.github.com/repos/ShooterTT/gringotts/assignees{/user}","branches_url":"https://api.github.com/repos/ShooterTT/gringotts/branches{/branch}","tags_url":"https://api.github.com/repos/ShooterTT/gringotts/tags","blobs_url":"https://api.github.com/repos/ShooterTT/gringotts/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ShooterTT/gringotts/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ShooterTT/gringotts/git/refs{/sha}","trees_url":"https://api.github.com/repos/ShooterTT/gringotts/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ShooterTT/gringotts/statuses/{sha}","languages_url":"https://api.github.com/repos/ShooterTT/gringotts/languages","stargazers_url":"https://api.github.com/repos/ShooterTT/gringotts/stargazers","contributors_url":"https://api.github.com/repos/ShooterTT/gringotts/contributors","subscribers_url":"https://api.github.com/repos/ShooterTT/gringotts/subscribers","subscription_url":"https://api.github.com/repos/ShooterTT/gringotts/subscription","commits_url":"https://api.github.com/repos/ShooterTT/gringotts/commits{/sha}","git_commits_url":"https://api.github.com/repos/ShooterTT/gringotts/git/commits{/sha}","comments_url":"https://api.github.com/repos/ShooterTT/gringotts/comments{/number}","issue_comment_url":"https://api.github.com/repos/ShooterTT/gringotts/issues/comments{/number}","contents_url":"https://api.github.com/repos/ShooterTT/gringotts/contents/{+path}","compare_url":"https://api.github.com/repos/ShooterTT/gringotts/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ShooterTT/gringotts/merges","archive_url":"https://api.github.com/repos/ShooterTT/gringotts/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ShooterTT/gringotts/downloads","issues_url":"https://api.github.com/repos/ShooterTT/gringotts/issues{/number}","pulls_url":"https://api.github.com/repos/ShooterTT/gringotts/pulls{/number}","milestones_url":"https://api.github.com/repos/ShooterTT/gringotts/milestones{/number}","notifications_url":"https://api.github.com/repos/ShooterTT/gringotts/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ShooterTT/gringotts/labels{/name}","releases_url":"https://api.github.com/repos/ShooterTT/gringotts/releases{/id}","deployments_url":"https://api.github.com/repos/ShooterTT/gringotts/deployments","created_at":"2016-05-24T06:21:37Z","updated_at":"2016-05-24T06:21:39Z","pushed_at":"2016-06-02T09:21:48Z","git_url":"git://github.com/ShooterTT/gringotts.git","ssh_url":"git@github.com:ShooterTT/gringotts.git","clone_url":"https://github.com/ShooterTT/gringotts.git","svn_url":"https://github.com/ShooterTT/gringotts","homepage":"","size":1108,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"unitedstack:master","ref":"master","sha":"ff1e3283608b7ed159c5d8c5c47f911db8fc60a3","user":{"login":"unitedstack","id":3347023,"avatar_url":"https://avatars.githubusercontent.com/u/3347023?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstack","html_url":"https://github.com/unitedstack","followers_url":"https://api.github.com/users/unitedstack/followers","following_url":"https://api.github.com/users/unitedstack/following{/other_user}","gists_url":"https://api.github.com/users/unitedstack/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstack/subscriptions","organizations_url":"https://api.github.com/users/unitedstack/orgs","repos_url":"https://api.github.com/users/unitedstack/repos","events_url":"https://api.github.com/users/unitedstack/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstack/received_events","type":"Organization","site_admin":false},"repo":{"id":49847387,"name":"gringotts","full_name":"unitedstack/gringotts","owner":{"login":"unitedstack","id":3347023,"avatar_url":"https://avatars.githubusercontent.com/u/3347023?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstack","html_url":"https://github.com/unitedstack","followers_url":"https://api.github.com/users/unitedstack/followers","following_url":"https://api.github.com/users/unitedstack/following{/other_user}","gists_url":"https://api.github.com/users/unitedstack/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstack/subscriptions","organizations_url":"https://api.github.com/users/unitedstack/orgs","repos_url":"https://api.github.com/users/unitedstack/repos","events_url":"https://api.github.com/users/unitedstack/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstack/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/unitedstack/gringotts","description":"A billing service for OpenStack","fork":false,"url":"https://api.github.com/repos/unitedstack/gringotts","forks_url":"https://api.github.com/repos/unitedstack/gringotts/forks","keys_url":"https://api.github.com/repos/unitedstack/gringotts/keys{/key_id}","collaborators_url":"https://api.github.com/repos/unitedstack/gringotts/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/unitedstack/gringotts/teams","hooks_url":"https://api.github.com/repos/unitedstack/gringotts/hooks","issue_events_url":"https://api.github.com/repos/unitedstack/gringotts/issues/events{/number}","events_url":"https://api.github.com/repos/unitedstack/gringotts/events","assignees_url":"https://api.github.com/repos/unitedstack/gringotts/assignees{/user}","branches_url":"https://api.github.com/repos/unitedstack/gringotts/branches{/branch}","tags_url":"https://api.github.com/repos/unitedstack/gringotts/tags","blobs_url":"https://api.github.com/repos/unitedstack/gringotts/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/unitedstack/gringotts/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/unitedstack/gringotts/git/refs{/sha}","trees_url":"https://api.github.com/repos/unitedstack/gringotts/git/trees{/sha}","statuses_url":"https://api.github.com/repos/unitedstack/gringotts/statuses/{sha}","languages_url":"https://api.github.com/repos/unitedstack/gringotts/languages","stargazers_url":"https://api.github.com/repos/unitedstack/gringotts/stargazers","contributors_url":"https://api.github.com/repos/unitedstack/gringotts/contributors","subscribers_url":"https://api.github.com/repos/unitedstack/gringotts/subscribers","subscription_url":"https://api.github.com/repos/unitedstack/gringotts/subscription","commits_url":"https://api.github.com/repos/unitedstack/gringotts/commits{/sha}","git_commits_url":"https://api.github.com/repos/unitedstack/gringotts/git/commits{/sha}","comments_url":"https://api.github.com/repos/unitedstack/gringotts/comments{/number}","issue_comment_url":"https://api.github.com/repos/unitedstack/gringotts/issues/comments{/number}","contents_url":"https://api.github.com/repos/unitedstack/gringotts/contents/{+path}","compare_url":"https://api.github.com/repos/unitedstack/gringotts/compare/{base}...{head}","merges_url":"https://api.github.com/repos/unitedstack/gringotts/merges","archive_url":"https://api.github.com/repos/unitedstack/gringotts/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/unitedstack/gringotts/downloads","issues_url":"https://api.github.com/repos/unitedstack/gringotts/issues{/number}","pulls_url":"https://api.github.com/repos/unitedstack/gringotts/pulls{/number}","milestones_url":"https://api.github.com/repos/unitedstack/gringotts/milestones{/number}","notifications_url":"https://api.github.com/repos/unitedstack/gringotts/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/unitedstack/gringotts/labels{/name}","releases_url":"https://api.github.com/repos/unitedstack/gringotts/releases{/id}","deployments_url":"https://api.github.com/repos/unitedstack/gringotts/deployments","created_at":"2016-01-18T02:38:23Z","updated_at":"2016-05-25T05:22:27Z","pushed_at":"2016-06-02T09:47:10Z","git_url":"git://github.com/unitedstack/gringotts.git","ssh_url":"git@github.com:unitedstack/gringotts.git","clone_url":"https://github.com/unitedstack/gringotts.git","svn_url":"https://github.com/unitedstack/gringotts","homepage":"","size":1087,"stargazers_count":6,"watchers_count":6,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":1,"forks":3,"open_issues":1,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/1"},"html":{"href":"https://github.com/unitedstack/gringotts/pull/1"},"issue":{"href":"https://api.github.com/repos/unitedstack/gringotts/issues/1"},"comments":{"href":"https://api.github.com/repos/unitedstack/gringotts/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/unitedstack/gringotts/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/unitedstack/gringotts/statuses/da5790790c42bd39468398d36b1f311ef8e9f458"}}}}
{"actor":{"display_login":"hackerain"}}