{"action":"closed","issue":{"url":"https://api.github.com/repos/numpy/numpy/issues/5632","labels_url":"https://api.github.com/repos/numpy/numpy/issues/5632/labels{/name}","comments_url":"https://api.github.com/repos/numpy/numpy/issues/5632/comments","events_url":"https://api.github.com/repos/numpy/numpy/issues/5632/events","html_url":"https://github.com/numpy/numpy/issues/5632","id":59852762,"number":5632,"title":"When accessing multiple fields of a structured array, existence is not checked and return dtype may be empty","user":{"login":"gerritholl","id":500246,"avatar_url":"https://avatars.githubusercontent.com/u/500246?v=3","gravatar_id":"","url":"https://api.github.com/users/gerritholl","html_url":"https://github.com/gerritholl","followers_url":"https://api.github.com/users/gerritholl/followers","following_url":"https://api.github.com/users/gerritholl/following{/other_user}","gists_url":"https://api.github.com/users/gerritholl/gists{/gist_id}","starred_url":"https://api.github.com/users/gerritholl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gerritholl/subscriptions","organizations_url":"https://api.github.com/users/gerritholl/orgs","repos_url":"https://api.github.com/users/gerritholl/repos","events_url":"https://api.github.com/users/gerritholl/events{/privacy}","received_events_url":"https://api.github.com/users/gerritholl/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-03-04T19:59:40Z","updated_at":"2015-07-29T01:48:46Z","closed_at":"2015-07-29T01:48:46Z","body":"When accessing multiple fields of a structured array, numpy fails to verify that all the fields exist.  Instead, it will only return existing fields.  If none exist, it return a strange object that has a dtype that is empty.  Normally, creating an object with an empty dtype is not supposed to be possible (`zeros(shape=(5,), dtype=[])` results as expected in `TypeError: Empty data-type`), so this might actually be a dual bug.\r\n\r\n```\r\nIn [216]: A = numpy.empty(dtype=[(\"A\", \"f4\"), (\"B\", \"f8\")], shape=(5,))\r\n\r\nIn [217]: A[[\"AA\"]]\r\nOut[217]: \r\narray([(), (), (), (), ()], \r\n      dtype='{'names':[], 'formats':[], 'offsets':[], 'itemsize':12}')\r\n\r\nIn [232]: A[[\"AA\", \"B\"]]\r\nOut[232]: \r\narray([(0.0,), (0.0,), (0.0,), (0.0,), (0.0,)], \r\n      dtype=[('B', '<f8')])\r\n```"}}