@@ -75,8 +75,8 @@ def mission(self):
7575
7676 @mission .setter
7777 def mission (self , value ):
78- # Need to update the service parameters if the mission is changed
79- self ._mission = value .lower ()
78+ # Setter that updates the service parameters if the mission is changed
79+ self ._mission = value .lower () # case-insensitive
8080 self ._service_api_connection .set_service_params (self .service_dict , f'search/{ self .mission } ' )
8181
8282 def _parse_result (self , response , * , verbose = False ): # Used by the async_to_sync decorator functionality
@@ -100,7 +100,7 @@ def _parse_result(self, response, *, verbose=False): # Used by the async_to_syn
100100 if self .service == self ._search :
101101 results = self ._service_api_connection ._parse_result (response , verbose , data_key = 'results' )
102102 elif self .service == self ._list_products :
103- # Results from list_products endpoint need to be handled differently
103+ # Results from post_list_products endpoint need to be handled differently
104104 results = Table (response .json ()['products' ])
105105
106106 if len (results ) >= self .limit :
@@ -510,8 +510,9 @@ def download_file(self, uri, *, local_path=None, cache=True, verbose=True):
510510 if err .response .status_code == 401 :
511511 no_auth_msg = f'You are not authorized to download from { data_url } .'
512512 if self ._authenticated :
513- no_auth_msg += ('\n Please check your authentication token. You can generate a new '
514- 'token at https://auth.mast.stsci.edu/token?suggested_name=Astroquery&'
513+ no_auth_msg += ('\n You do not have access to download this data, or your authentication '
514+ 'token may be expired. You can generate a new token at '
515+ 'https://auth.mast.stsci.edu/token?suggested_name=Astroquery&'
515516 'suggested_scope=mast:exclusive_access' )
516517 else :
517518 no_auth_msg += ('\n Please authenticate yourself using the `~astroquery.mast.MastMissions.login` '
0 commit comments