Skip to content

Commit c66f83d

Browse files
committed
Deprecate astroquery/utils/download_file_list.py
This commit deprecates the function `download_list_of_fitsfiles()`, and because that is the only public function defined by the aforementioned file then the whole file becomes deprecated.
1 parent 8a60cd2 commit c66f83d

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

astroquery/utils/download_file_list.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
from io import StringIO
77

88
import astropy.io.fits as fits
9+
from astropy.utils.decorators import deprecated
910
from .commons import get_readable_fileobj
1011

1112
__all__ = ['download_list_of_fitsfiles']
@@ -26,6 +27,7 @@ def validify_filename(filestr):
2627
return filestr
2728

2829

30+
@deprecated('0.4.5')
2931
def download_list_of_fitsfiles(linklist, output_directory=None,
3032
output_prefix=None, save=False,
3133
overwrite=False, verbose=False,
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import pytest
2+
3+
from astropy.utils.exceptions import AstropyDeprecationWarning
4+
5+
from astroquery.utils.download_file_list import download_list_of_fitsfiles
6+
7+
8+
def test_download_list_of_fitsfiles_deprecation():
9+
with pytest.warns(AstropyDeprecationWarning):
10+
download_list_of_fitsfiles([])

0 commit comments

Comments
 (0)