Regression: Series.loc.setitem raising with all false indexer and series on rhs
State: closed

- [x] closes #45778 (Replace xxxx with the Github issue number)
- [x] [Tests added and passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#writing-tests) if fixing a bug or adding a new feature
- [x] All [code checks passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#pre-commit).
- [x] Added an entry in the latest `doc/source/whatsnew/vX.X.X.rst` file if fixing a bug or adding a new feature.

This is really annoying. We are treating setting to a Series with all False indexer differently than to a DataFrame. Series raises, DataFrame not. Series does not raise, when rhs is a Series itself (only case as far as I can see). We should think about cleaning that up.

Labels:
name: Indexing
description: Related to indexing on series/frames, not to indexes themselves
name: Regression
description: Functionality that used to work in a prior pandas version

Comments:
@meeseeksdev backport 1.4.x
Owee, I'm MrMeeseeks, Look at me.

There seem to be a conflict, please backport manually. Here are approximate instructions:

1. Checkout backport branch and update it.

```
git checkout 1.4.x
git pull
```

2. Cherry pick the first parent branch of the this PR on top of the older branch:
```
git cherry-pick -m1 aafd4c81f691bb8c40752c523e5c942d6d2bbb82
```

3. You will likely have some merge/cherry-pick conflict here, fix them and commit:

```
git commit -am 'Backport PR #45784: Regression: Series.loc.setitem raising with all false indexer and series on rhs'
```

4. Push to a named branch:

```
git push YOURFORK 1.4.x:auto-backport-of-pr-45784-on-1.4.x
```

5. Create a PR against branch 1.4.x, I would have named this PR:

> "Backport PR #45784 on branch 1.4.x (Regression: Series.loc.setitem raising with all false indexer and series on rhs)"

And apply the correct labels and milestones.

Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon!

Remember to remove the `Still Needs Manual Backport` label once the PR gets merged.

If these instructions are inaccurate, feel free to [suggest an improvement](https://github.com/MeeseeksBox/MeeseeksDev).
                
thanks @phofl 

certainly let's open an issue about consistent indexing here with boolean indexers (and PR if you can :->)
Owee, I'm MrMeeseeks, Look at me.

There seem to be a conflict, please backport manually. Here are approximate instructions:

1. Checkout backport branch and update it.

```
git checkout 1.4.x
git pull
```

2. Cherry pick the first parent branch of the this PR on top of the older branch:
```
git cherry-pick -m1 aafd4c81f691bb8c40752c523e5c942d6d2bbb82
```

3. You will likely have some merge/cherry-pick conflict here, fix them and commit:

```
git commit -am 'Backport PR #45784: Regression: Series.loc.setitem raising with all false indexer and series on rhs'
```

4. Push to a named branch:

```
git push YOURFORK 1.4.x:auto-backport-of-pr-45784-on-1.4.x
```

5. Create a PR against branch 1.4.x, I would have named this PR:

> "Backport PR #45784 on branch 1.4.x (Regression: Series.loc.setitem raising with all false indexer and series on rhs)"

And apply the correct labels and milestones.

Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon!

Remember to remove the `Still Needs Manual Backport` label once the PR gets merged.

If these instructions are inaccurate, feel free to [suggest an improvement](https://github.com/MeeseeksBox/MeeseeksDev).
                
merge conflict due to #45403
I think the behavior I mentioned above was aligned in #45501 (not 100% sure if that was the cause, but it is consistent now)