Skip to content

Commit

Permalink
filename is the second return from mkstemp
Browse files Browse the repository at this point in the history
  • Loading branch information
keflavich committed Dec 23, 2021
1 parent c045f86 commit 5b3ad61
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spectral_cube/dask_spectral_cube.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def wrapper(self, *args, **kwargs):
raise ImportError("saving the cube to a temporary directory "
"requires the zarr and fsspec packages to "
"be installed.")
filename = tempfile.mkstemp()
filenum, filename = tempfile.mkstemp()
with dask.config.set(**cube._scheduler_kwargs):
cube._data.to_zarr(filename)
cube._data = da.from_zarr(filename)
Expand Down

0 comments on commit 5b3ad61

Please sign in to comment.