{"action":"created","issue":{"url":"https://api.github.com/repos/astropy/astropy/issues/6127","repository_url":"https://api.github.com/repos/astropy/astropy","labels_url":"https://api.github.com/repos/astropy/astropy/issues/6127/labels{/name}","comments_url":"https://api.github.com/repos/astropy/astropy/issues/6127/comments","events_url":"https://api.github.com/repos/astropy/astropy/issues/6127/events","html_url":"https://github.com/astropy/astropy/pull/6127","id":232057500,"number":6127,"title":"Add a new to_value method to Quantity.","user":{"login":"mhvk","id":2789820,"avatar_url":"https://avatars3.githubusercontent.com/u/2789820?v=3","gravatar_id":"","url":"https://api.github.com/users/mhvk","html_url":"https://github.com/mhvk","followers_url":"https://api.github.com/users/mhvk/followers","following_url":"https://api.github.com/users/mhvk/following{/other_user}","gists_url":"https://api.github.com/users/mhvk/gists{/gist_id}","starred_url":"https://api.github.com/users/mhvk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhvk/subscriptions","organizations_url":"https://api.github.com/users/mhvk/orgs","repos_url":"https://api.github.com/users/mhvk/repos","events_url":"https://api.github.com/users/mhvk/events{/privacy}","received_events_url":"https://api.github.com/users/mhvk/received_events","type":"User","site_admin":false},"labels":[{"id":68702422,"url":"https://api.github.com/repos/astropy/astropy/labels/Affects-release","name":"Affects-release","color":"0052cc","default":false},{"id":12456977,"url":"https://api.github.com/repos/astropy/astropy/labels/units","name":"units","color":"c7def8","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/astropy/astropy/milestones/42","html_url":"https://github.com/astropy/astropy/milestone/42","labels_url":"https://api.github.com/repos/astropy/astropy/milestones/42/labels","id":2169283,"number":42,"title":"v2.0.0","description":"","creator":{"login":"astrofrog","id":314716,"avatar_url":"https://avatars1.githubusercontent.com/u/314716?v=3","gravatar_id":"","url":"https://api.github.com/users/astrofrog","html_url":"https://github.com/astrofrog","followers_url":"https://api.github.com/users/astrofrog/followers","following_url":"https://api.github.com/users/astrofrog/following{/other_user}","gists_url":"https://api.github.com/users/astrofrog/gists{/gist_id}","starred_url":"https://api.github.com/users/astrofrog/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/astrofrog/subscriptions","organizations_url":"https://api.github.com/users/astrofrog/orgs","repos_url":"https://api.github.com/users/astrofrog/repos","events_url":"https://api.github.com/users/astrofrog/events{/privacy}","received_events_url":"https://api.github.com/users/astrofrog/received_events","type":"User","site_admin":false},"open_issues":57,"closed_issues":114,"state":"open","created_at":"2016-12-01T16:34:27Z","updated_at":"2017-05-30T17:21:12Z","due_on":"2017-06-17T07:00:00Z","closed_at":null},"comments":11,"created_at":"2017-05-29T16:00:54Z","updated_at":"2017-05-30T17:46:54Z","closed_at":"2017-05-30T17:01:39Z","pull_request":{"url":"https://api.github.com/repos/astropy/astropy/pulls/6127","html_url":"https://github.com/astropy/astropy/pull/6127","diff_url":"https://github.com/astropy/astropy/pull/6127.diff","patch_url":"https://github.com/astropy/astropy/pull/6127.patch"},"body":"This returns the value of the quantity in the given unit.\r\n\r\n@taldcroft: I ended up with `to_value` as I felt it was a bit more uniform (with `to_string`, etc.) and makes more sense without arguments (a form that needs to exist to make the property work, i.e., `q.to_value()` is obvious but `q.value_in()` is not). I also ended up not using it for `to`, as especially the scalar case is slowed down a little too much by first doing `value.item()` and then recreating an array in `_new_view`.\r\n\r\nFixes #6125 \r\n"},"comment":{"url":"https://api.github.com/repos/astropy/astropy/issues/comments/304955365","html_url":"https://github.com/astropy/astropy/pull/6127#issuecomment-304955365","issue_url":"https://api.github.com/repos/astropy/astropy/issues/6127","id":304955365,"user":{"login":"mhvk","id":2789820,"avatar_url":"https://avatars3.githubusercontent.com/u/2789820?v=3","gravatar_id":"","url":"https://api.github.com/users/mhvk","html_url":"https://github.com/mhvk","followers_url":"https://api.github.com/users/mhvk/followers","following_url":"https://api.github.com/users/mhvk/following{/other_user}","gists_url":"https://api.github.com/users/mhvk/gists{/gist_id}","starred_url":"https://api.github.com/users/mhvk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhvk/subscriptions","organizations_url":"https://api.github.com/users/mhvk/orgs","repos_url":"https://api.github.com/users/mhvk/repos","events_url":"https://api.github.com/users/mhvk/events{/privacy}","received_events_url":"https://api.github.com/users/mhvk/received_events","type":"User","site_admin":false},"created_at":"2017-05-30T17:46:54Z","updated_at":"2017-05-30T17:46:54Z","body":"In principle, yes, but I think that would at the minimum involve getting `asv` working again, so we can quantify what the improvement actually is!"}}
{"actor":{"display_login":"mhvk"}}