{"action":"created","issue":{"url":"https://api.github.com/repos/numpy/numpy/issues/9691","repository_url":"https://api.github.com/repos/numpy/numpy","labels_url":"https://api.github.com/repos/numpy/numpy/issues/9691/labels{/name}","comments_url":"https://api.github.com/repos/numpy/numpy/issues/9691/comments","events_url":"https://api.github.com/repos/numpy/numpy/issues/9691/events","html_url":"https://github.com/numpy/numpy/pull/9691","id":257995610,"number":9691,"title":"PEP 3141 numbers should be considered scalars","user":{"login":"jdemeyer","id":3625785,"avatar_url":"https://avatars0.githubusercontent.com/u/3625785?v=4","gravatar_id":"","url":"https://api.github.com/users/jdemeyer","html_url":"https://github.com/jdemeyer","followers_url":"https://api.github.com/users/jdemeyer/followers","following_url":"https://api.github.com/users/jdemeyer/following{/other_user}","gists_url":"https://api.github.com/users/jdemeyer/gists{/gist_id}","starred_url":"https://api.github.com/users/jdemeyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdemeyer/subscriptions","organizations_url":"https://api.github.com/users/jdemeyer/orgs","repos_url":"https://api.github.com/users/jdemeyer/repos","events_url":"https://api.github.com/users/jdemeyer/events{/privacy}","received_events_url":"https://api.github.com/users/jdemeyer/received_events","type":"User","site_admin":false},"labels":[{"id":6359239,"url":"https://api.github.com/repos/numpy/numpy/labels/01%20-%20Enhancement","name":"01 - Enhancement","color":"fef2c0","default":false},{"id":16917029,"url":"https://api.github.com/repos/numpy/numpy/labels/component:%20numpy.core","name":"component: numpy.core","color":"009800","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":18,"created_at":"2017-09-15T10:28:25Z","updated_at":"2017-10-21T20:50:18Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/numpy/numpy/pulls/9691","html_url":"https://github.com/numpy/numpy/pull/9691","diff_url":"https://github.com/numpy/numpy/pull/9691.diff","patch_url":"https://github.com/numpy/numpy/pull/9691.patch"},"body":"The function `numpy.isscalar()` should recognize all [PEP 3141](https://www.python.org/dev/peps/pep-3141/) numbers as scalars.\r\n\r\nThe underlying issue is that the upgrade to SciPy 0.19.1 broke `lil_matrix()` with Sage Integers as input, because SciPy now uses `numpy.isscalar()` to validate certain inputs.\r\n\r\nDownstream: https://trac.sagemath.org/ticket/23867"},"comment":{"url":"https://api.github.com/repos/numpy/numpy/issues/comments/338431471","html_url":"https://github.com/numpy/numpy/pull/9691#issuecomment-338431471","issue_url":"https://api.github.com/repos/numpy/numpy/issues/9691","id":338431471,"user":{"login":"eric-wieser","id":425260,"avatar_url":"https://avatars3.githubusercontent.com/u/425260?v=4","gravatar_id":"","url":"https://api.github.com/users/eric-wieser","html_url":"https://github.com/eric-wieser","followers_url":"https://api.github.com/users/eric-wieser/followers","following_url":"https://api.github.com/users/eric-wieser/following{/other_user}","gists_url":"https://api.github.com/users/eric-wieser/gists{/gist_id}","starred_url":"https://api.github.com/users/eric-wieser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eric-wieser/subscriptions","organizations_url":"https://api.github.com/users/eric-wieser/orgs","repos_url":"https://api.github.com/users/eric-wieser/repos","events_url":"https://api.github.com/users/eric-wieser/events{/privacy}","received_events_url":"https://api.github.com/users/eric-wieser/received_events","type":"User","site_admin":false},"created_at":"2017-10-21T20:50:18Z","updated_at":"2017-10-21T20:50:18Z","author_association":"MEMBER","body":"> look carefully in our own code base what isscalar is actually used for\r\n\r\nThe answer is:\r\n\r\n* That case in `np.linspace`\r\n* np.piecewise, which is probably easy to fix\r\n* np.histogramdd, which might be a little more work\r\n* A poorly-behaved `np.ma.apply_along_axis` (#8511)\r\n* Code that we're only keeping around for compatibility anyway (best to leave?)\r\n  * What is probably just an optimization in operator overloads in `np.poly1d`\r\n  * Broken stuff in `defmatrix` that we probably can't change now anyway:\r\n    ```\r\n    >>> a[:,0]\r\n    matrix([[ 1.],\r\n            [ 0.]])\r\n    >>> a[:,np.array(0)]\r\n    matrix([[ 1.,  0.]])\r\n    ```\r\n\r\n\r\n\r\n\r\n"}}
{"actor":{"display_login":"eric-wieser"}}