Skip to content

Commit b7527f9

Browse files
code sample for pandas-dev#45778
1 parent 180f329 commit b7527f9

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

bisect/45778.py

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# BUG: setting with loc breaks in 1.4.0 when indexing using an all-False boolean series #45778
2+
3+
import pandas as pd
4+
5+
print(pd.__version__)
6+
7+
foo = pd.Series([1, 2, 3, 4, 5], index=["a", "b", "c", "d", "e"])
8+
bar = pd.Series([6, 7, 8, 9, 10], index=["a", "b", "c", "d", "e"])
9+
10+
# works in 1.3 but breaks in 1.4
11+
foo.loc[foo > 100] = bar
12+
print(foo)

0 commit comments

Comments
 (0)