desihub / desisim

DESI simulations
BSD 3-Clause "New" or "Revised" License
16 stars 22 forks source link

fitsio str vs. bytes #542

Closed sbailey closed 4 years ago

sbailey commented 4 years ago

More updates for supporting fitsio 1.x (str) vs. <1 (bytes), this time in desisim.simexp.read_mock_spectra. It includes a new unit test that piggy backs upon the test mock spectra in desitarget.

This also updates desisim.io.write_simspec to use a temporary file when writing to avoid partially written files with the final filename.

Reviews from anyone are welcome, but this is needed for next software release so I'll leave it open for a bit while testing other repos, but I will self merge this when needed for a desisim tag.