I\'ve narrowed down to this call:
fig.canvas.tostring_argb() #fig=matplotlib.pyplot.figure()
this function raises an AttributeError
AttributeError
I ended up installing and using the WXAgg backend; the Agg,and default GTKAgg, didn't work for me.
WXAgg
Agg
GTKAgg