OSError: read past end of file - pycortex quickflat.make_png

Hi,

I’m trying to save/show some flatmaps as pngs (by using cortex.quickflat.make_png) and get this error:

Unknown option --export-filename

OSError Traceback (most recent call last)
in
----> 1 _ = cortex.quickflat.make_figure(tsnr_flat)
2 plt.show()

~/pycortex/cortex/quickflat/view.py in make_figure(braindata, recache, pixelwise, thick, sampler, height, dpi, depth, with_rois, with_sulci, with_labels, with_colorbar, with_borders, with_dropout, with_curvature, extra_disp, with_connected_vertices, overlay_file, linewidth, linecolor, roifill, shadow, labelsize, labelcolor, cutout, curvature_brightness, curvature_contrast, curvature_threshold, fig, extra_hatch, colorbar_ticks, colorbar_location, roi_list, nanmean, **kwargs)
198 roifill=roifill, shadow=shadow, labelsize=labelsize, labelcolor=labelcolor,
199 with_labels=with_labels, overlay_file=overlay_file,
→ 200 roi_list=roi_list)
201 layers[‘rois’] = roi_im
202 # Add sulci

~/pycortex/cortex/quickflat/composite.py in add_rois(fig, dataview, extents, height, with_labels, roi_list, overlay_file, **kwargs)
209 layer_kws = _parse_defaults(‘rois_paths’)
210 layer_kws.update(svg_kws)
→ 211 im = svgobject.get_texture(‘rois’, height, labels=with_labels, shape_list=roi_list, **layer_kws)
212 _, ax = _get_fig_and_ax(fig)
213 img = ax.imshow(im,

~/pycortex/cortex/svgoverlay.py in get_texture(self, layer_name, height, name, background, labels, shape_list, **kwargs)
290 if name is None:
291 png.seek(0)
→ 292 im = plt.imread(png)
293 return im
294

~/anaconda3/envs/i36/lib/python3.6/site-packages/matplotlib/pyplot.py in imread(fname, format)
2150 @docstring.copy_dedent(matplotlib.image.imread)
2151 def imread(fname, format=None):
→ 2152 return matplotlib.image.imread(fname, format)
2153
2154

~/anaconda3/envs/i36/lib/python3.6/site-packages/matplotlib/image.py in imread(fname, format)
1367 return handler(fd)
1368 else:
→ 1369 return handler(fname)
1370
1371

OSError: read past end of file

Not sure what’s going on and how to solve it. When I use cortex.webshow() it opens the data in the browser, as normal.
I’m using python 3.6.12 and pycortex 1.3.0.dev23

Similar to make Inkscape command line option explicit by tknapen · Pull Request #357 · gallantlab/pycortex · GitHub, fixed