{"action":"closed","issue":{"url":"https://api.github.com/repos/pydata/pandas/issues/9596","labels_url":"https://api.github.com/repos/pydata/pandas/issues/9596/labels{/name}","comments_url":"https://api.github.com/repos/pydata/pandas/issues/9596/comments","events_url":"https://api.github.com/repos/pydata/pandas/issues/9596/events","html_url":"https://github.com/pydata/pandas/issues/9596","id":59970070,"number":9596,"title":"Error when updating dataframe with empty filter","user":{"login":"Sereger13","id":10167353,"avatar_url":"https://avatars.githubusercontent.com/u/10167353?v=3","gravatar_id":"","url":"https://api.github.com/users/Sereger13","html_url":"https://github.com/Sereger13","followers_url":"https://api.github.com/users/Sereger13/followers","following_url":"https://api.github.com/users/Sereger13/following{/other_user}","gists_url":"https://api.github.com/users/Sereger13/gists{/gist_id}","starred_url":"https://api.github.com/users/Sereger13/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sereger13/subscriptions","organizations_url":"https://api.github.com/users/Sereger13/orgs","repos_url":"https://api.github.com/users/Sereger13/repos","events_url":"https://api.github.com/users/Sereger13/events{/privacy}","received_events_url":"https://api.github.com/users/Sereger13/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pydata/pandas/labels/Bug","name":"Bug","color":"e10c02"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Difficulty%20Intermediate","name":"Difficulty Intermediate","color":"fbca04"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Effort%20Low","name":"Effort Low","color":"006b75"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Error%20Reporting","name":"Error Reporting","color":"ffa0ff"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Indexing","name":"Indexing","color":"0b02e1"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/pydata/pandas/milestones/29","html_url":"https://github.com/pydata/pandas/milestones/0.16.1","labels_url":"https://api.github.com/repos/pydata/pandas/milestones/29/labels","id":816810,"number":29,"title":"0.16.1","description":"after 0.16.0 of course!","creator":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","followers_url":"https://api.github.com/users/jreback/followers","following_url":"https://api.github.com/users/jreback/following{/other_user}","gists_url":"https://api.github.com/users/jreback/gists{/gist_id}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"open_issues":110,"closed_issues":119,"state":"open","created_at":"2014-10-07T14:39:07Z","updated_at":"2015-04-18T20:42:41Z","due_on":"2015-04-30T07:00:00Z","closed_at":null},"comments":7,"created_at":"2015-03-05T15:47:10Z","updated_at":"2015-04-18T20:42:41Z","closed_at":"2015-04-18T20:42:41Z","body":"```python\r\ndf = pd.DataFrame({'a': ['1', '2', '3'], \r\n               'b': ['11', '22', '33'], \r\n               'c': ['111', '222', '333']})\r\ndf.loc[df.b.isnull(), 'a'] = df.b\r\n```\r\nThe filtering condition is always false (b is never null) and the above code produces this error:\r\n`Array is not broadcastable to correct shape`.\r\n\r\nIf, however, I change the type for column 'c' - which is not even mentioned in the assignment expression (!) - from str to int,\r\n```python\r\ndf = pd.DataFrame({'a': ['1', '2', '3'], \r\n               'b': ['11', '22', '33'], \r\n               'c': [111, 222, 333]}) # Type changed to int\r\ndf.loc[df.b.isnull(), 'a'] = df.b\r\n```\r\nNo errors are produced.\r\n\r\nWould be nice to have consistent behaviour and not have any errors - could not find anything in the documentation saying that applying .loc on empty filter is considered illegal?\r\n"}}