Importing AstroPhotography imports classes that use astropy.astroquery Astrometry.net, which will always generate the following warning BEFORE any attempt to register the ey for the session:
WARNING: Astrometry.net API key not found in configuration file [astroquery.astrometry_net.core]
WARNING: You need to manually edit the configuration file and add it [astroquery.astrometry_net.core]
WARNING: You may also register it for this session with AstrometryNet.key = 'XXXXXXXX' [astroquery.astrometry_net.core]
See astropy/astroquery/issues/1544
The core issue here is this not a warning warning that can be suppressed the way other warnings can.
Options:
Work around this is some way, by checking the config file before loading the module, and writing a fake value in there if there isn't anything.
Add install instructions/script to set up config file.
Fix issue in astropy/astroquery/astrometry.net code and create a pull request?
Importing AstroPhotography imports classes that use astropy.astroquery Astrometry.net, which will always generate the following warning BEFORE any attempt to register the ey for the session:
See astropy/astroquery/issues/1544
The core issue here is this not a
warning
warning that can be suppressed the way other warnings can.Options: