Closed
Description
Bug report
Bug summary
Pickling errorbar plot with y axis error bars fails with error AttributeError: Can't pickle local object '_reverser.<locals>.freversed'
.
Code for reproduction
import matplotlib.pylab as plt
import pickle as pl
fig = plt.figure()
x = [1,2,3]
y = [4,5,6]
err = [0.1,0.1,0.1]
plt.errorbar(x,y, yerr=err)
pl.dump(fig, open('errorbar.pl', 'wb'))
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: Can't pickle local object '_reverser.<locals>.freversed'
Same code without specifying the y axis errors (plt.errorbar(x,y)
) pickles successfully.
Matplotlib version
- Operating system: Ubuntu 17.10
- Matplotlib version: 2.1.2
- Matplotlib backend (
print(matplotlib.get_backend())
): TkAgg - Python version: 3.6.2
Metadata
Metadata
Assignees
Labels
No labels