jacopo-chevallard / PyP-BEAGLE

4 stars 1 forks source link

Astropy 'clobber' argument not recognised, summary catalogues #50

Closed ImaanBontle closed 2 years ago

ImaanBontle commented 2 years ago

Hi Jacopo,

It appears that 'clobber' has been deprecated from AstroPy v5.1, preventing the computation of summary catalogues.

I am afraid I can't provide a copy of the error message, but it should be relatively easy to reproduce.

I believe the problem lies in the *.writeto() method of astropy.io.fits (see changelog), and that fixing it should be as straightforward as changing "clobber=overwrite" to "overwrite=true", or something to that effect.

I am not sure how backwards-compatible this change is. Rolling back to v5.0 is a temporary fix for now.

fdeugenio commented 2 years ago

Hi Jacopo and Imaan,

the keyword 'clobber' is replaced by 'overwrite'. So a reasonable substitution* would be:

replace 'clobber=' with 'overwrite='

Cheers,

Francesco

*Assuming you don't use 'clobber' elsewhere in the code!

PS. If you pass keywords as dictionaries, then also replace instances of 'clobber': and "clobber":

On 30/06/2022 11:20, ImaanBontle wrote:

Hi Jacopo,

It appears that 'clobber' has been deprecated from AstroPy v5.1, preventing the computation of summary catalogues.

I am afraid I can't provide a copy of the error message, but it should be relatively easy to reproduce.

I believe the problem lies in the *.writeto() method of astropy.io.fits (see changelog https://docs.astropy.org/en/stable/changelog.html#id4), and that fixing it should be as straightforward as changing "clobber=overwrite" to "overwrite=true", or something to that effect.

I am not sure how backwards-compatible this change is. Rolling back to v5.0 is a temporary fix for now.

— Reply to this email directly, view it on GitHub https://github.com/jacopo-chevallard/PyP-BEAGLE/issues/50, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD2YJD7Q4EIWAEECT2XU2NDVRVYINANCNFSM52I2AVHA. You are receiving this because you are subscribed to this thread.Message ID: @.***>