DavidT3 / XGA

X-ray: Generate and Analyse is a module designed to make the analysis of XMM observations simple and efficient. It provides an interface with SAS for the creation of XMM data products, as well as a way to easily perform fits (scalable for multiple observations) and retrieve information about an object, all within a Python package.
BSD 3-Clause "New" or "Revised" License
31 stars 3 forks source link

Reconsider when to trigger the Spectrum file header updating #1258

Open DavidT3 opened 2 weeks ago

DavidT3 commented 2 weeks ago

Currently it works like this:

if gen_cmd != "":
    try:
        self._update_spec_headers("main")
        self._update_spec_headers("back")
    except OSError as err:
        self._usable = False
        self._why_unusable.append("FITSIOOSError")

That is crude though, and I forgot about this behaviour when using CIAO to generate spectra and XGA products to organise them.

There has to be a better way of handling this?