File tree Expand file tree Collapse file tree 1 file changed +3
-14
lines changed Expand file tree Collapse file tree 1 file changed +3
-14
lines changed Original file line number Diff line number Diff line change 1
1
# Licensed under a 3-clause BSD style license - see LICENSE.rst
2
2
3
+ import gzip
3
4
import os
4
-
5
- # Import DEVNULL for py3 or py3
6
- try :
7
- from subprocess import DEVNULL
8
- except ImportError :
9
- DEVNULL = open (os .devnull , 'wb' )
10
-
11
- # Check availability of some system tools
12
- # Exceptions are raised if not found
5
+ import shutil
13
6
14
7
15
8
def gunzip (filename ):
@@ -19,17 +12,13 @@ def gunzip(filename):
19
12
----------
20
13
filename : str
21
14
Fully qualified path of the file to decompress.
15
+
22
16
Returns
23
17
-------
24
18
filename : str
25
19
Name of the decompressed file (or input filename if gzip is not
26
20
available).
27
21
"""
28
- import shutil
29
- import gzip
30
-
31
- # system-wide 'gzip' was removed, Python gzip used instead.
32
- # See #1538 : https://github.com/astropy/astroquery/issues/1538
33
22
34
23
# ".fz" denotes RICE rather than gzip compression
35
24
if not filename .endswith ('.fz' ):
You can’t perform that action at this time.
0 commit comments