Closed
Description
Code Sample, a copy-pastable example if possible
# In 0.17.1:
x = pd.Series(1/3)
x.map(lambda x: str(x)).to_dict()
{0: '0.333333333333'}
x.astype(str).map(lambda x: x).to_dict()
{0: '0.333333333333'}
# In 0.18.1:
x = pd.Series(1/3)
x.map(lambda x: str(x)).to_dict()
{0: '0.3333333333333333'}
x.astype(str).map(lambda x: x).to_dict()
{0: '0.333333333333'}
Expected Output
I'd expect the same output as in 0.17.x and before.
I do this a lot to convert floats to decimal.decimal with .map(lambda x: D(str(x))) which is slightly faster than using .astype(str).map(D).
This also messed up many of my unit-tests where I convert DFs to string dicts. Thanks to those I found this at all.
I checked the change docs but couldn't find something that points to why this should have changed.