2121from astropy .utils import deprecated
2222from astropy .utils .exceptions import AstropyDeprecationWarning
2323
24- from astroquery import version , log , conf
24+ from astroquery import version , log , cache_conf
2525from astroquery .utils import system_tools
2626
2727
@@ -311,7 +311,7 @@ def _request(self, method, url,
311311 is True.
312312 """
313313
314- cache &= conf .cache_active
314+ cache &= cache_conf .cache_active
315315
316316 if save :
317317 local_filename = url .split ('/' )[- 1 ]
@@ -335,13 +335,13 @@ def _request(self, method, url,
335335 query = AstroQuery (method , url , params = params , data = data , headers = headers ,
336336 files = files , timeout = timeout , json = json )
337337 if (self .cache_location is None ) or (not cache ):
338- with conf .set_temp ("cache_active" , False ):
338+ with cache_conf .set_temp ("cache_active" , False ):
339339 response = query .request (self ._session , stream = stream ,
340340 auth = auth , verify = verify ,
341341 allow_redirects = allow_redirects ,
342342 json = json )
343343 else :
344- response = query .from_cache (self .cache_location , conf .cache_timeout )
344+ response = query .from_cache (self .cache_location , cache_conf .cache_timeout )
345345 if not response :
346346 response = query .request (self ._session ,
347347 self .cache_location ,
@@ -485,7 +485,7 @@ class suspend_cache:
485485 """
486486
487487 def __init__ (self , obj = None ):
488- self .original_cache_setting = conf .cache_active
488+ self .original_cache_setting = cache_conf .cache_active
489489
490490 def __enter__ (self ):
491491 conf .cache_active = False
0 commit comments