GeminiDRSoftware / DRAGONS

Data Reduction for Astronomy from Gemini Observatory North and South
Other
27 stars 16 forks source link

Fix duplicate warnings correctly #430

Open KathleenLabrie opened 1 year ago

KathleenLabrie commented 1 year ago

Currently there is a quick fix in gempy/utils/logutils.py where we just blanket-filter the duplicate warnings: add_filter(DuplicateWarningFilter, log)

We need to find a better solution.

From Chris:

IIRC, we couldn't get the filter to work exactly how we wanted (if the final warning is repeated multiple times it doesn't announce that, because the "last warning was repeated N times" message only appears when a new warning is logged) and we were going to try to work out how to get the desired behaviour.

The biggest offender is the "Unmasking all points" message.