input
Series([True, False, True]).replace('fdsa','lkjh')
output
0 lkjh
1 False
2 lkjh
dtype: object
I would expect:
0 True
1 False
2 True
dtype: bool
This makes it quite annoying to work with boolean data. What is the reasoning behind the current behaviour?
s.astype(object).replace(....)