jvines / astroARIADNE

Easy stellar SED fitting!
MIT License
57 stars 7 forks source link

An error for HTTPError #33

Closed AstroJLin closed 2 years ago

AstroJLin commented 2 years ago

Hi,

Here, when I try to run s = Star(starname, ra, dec, g_id=gaia_id), an error is reported. Can you give some suggestions to solve this error?

Thanks!

The error is as follow:

Screenshot from 2022-06-23 19-21-12

jvines commented 2 years ago

Hi.

please when reporting a bug always include the full stack. I have absolutely no way of knowing what might be happening with the information provided

AstroJLin commented 2 years ago

Ok, the error is as follow:

In [18]: ra = 75.795 ...: dec = -30.399 ...: starname = 'NGTS-6' ...: gaia_id = 4875693023844840448 ...: ...: s = Star(starname, ra, dec, g_id=gaia_id)

    #####################################
    ##             ARIADNE             ##
    #####################################

spectrAl eneRgy dIstribution bAyesian moDel averagiNg fittEr

        Author : Jose Vines
        Contact : jose . vines at ug . uchile . cl
        Star : NGTS-6
    *** LOOKING UP ARCHIVAL INFORMATION ***

HTTPError Traceback (most recent call last) Input In [18], in <cell line: 6>() 3 starname = 'NGTS-6' 4 gaia_id = 4875693023844840448 ----> 6 s = Star(starname, ra, dec, g_id=gaia_id)

File ~/anaconda3/lib/python3.9/site-packages/astroARIADNE-0.5.5-py3.9.egg/astroARIADNE/star.py:181, in Star.init(self, starname, ra, dec, g_id, plx, plx_e, rad, rad_e, temp, temp_e, lum, lum_e, dist, dist_e, Av, Av_e, offline, mag_dict, verbose, ignore, dustmap) 176 if verbose: 177 print( 178 colored('\t\t LOOKING UP ARCHIVAL INFORMATION ', 179 c) 180 ) --> 181 lib = Librarian(starname, self.ra, self.dec, g_id=self.g_id, 182 mags=self.get_mags, ignore=ignore) 183 self.g_id = lib.g_id 184 self.tic = lib.tic

File ~/anaconda3/lib/python3.9/site-packages/astroARIADNE-0.5.5-py3.9.egg/astroARIADNE/librarian.py:160, in Librarian.init(self, starname, ra, dec, radius, g_id, mags, ignore) 157 else: 158 self.g_id = g_id --> 160 self.gaia_params() 161 if mags: 162 self.gaia_query()

File ~/anaconda3/lib/python3.9/site-packages/astroARIADNE-0.5.5-py3.9.egg/astroARIADNE/librarian.py:186, in Librarian.gaia_params(self) 184 query += ' from gaiadr2.gaia_source as gaia' 185 query += ' where gaia.source_id={0}'.format(self.g_id) --> 186 j = Gaia.launch_job_async(query) 187 res = j.get_results() 188 self.plx, self.plx_e = self._get_parallax(res)

File ~/anaconda3/lib/python3.9/site-packages/astroquery-0.4.7.dev7761-py3.9.egg/astroquery/gaia/core.py:903, in GaiaClass.launch_job_async(self, query, name, output_file, output_format, verbose, dump_to_file, background, upload_resource, upload_table_name, autorun) 862 def launch_job_async(self, query, name=None, output_file=None, 863 output_format="votable", verbose=False, 864 dump_to_file=False, background=False, 865 upload_resource=None, upload_table_name=None, 866 autorun=True): 867 """Launches an asynchronous job 868 869 Parameters (...) 901 A Job object 902 """ --> 903 return TapPlus.launch_job_async(self, query=query, 904 name=name, 905 output_file=output_file, 906 output_format=output_format, 907 verbose=verbose, 908 dump_to_file=dump_to_file, 909 background=background, 910 upload_resource=upload_resource, 911 upload_table_name=upload_table_name, 912 autorun=autorun)

File ~/anaconda3/lib/python3.9/site-packages/astroquery-0.4.7.dev7761-py3.9.egg/astroquery/utils/tap/core.py:440, in Tap.launch_job_async(self, query, name, output_file, output_format, verbose, dump_to_file, background, upload_resource, upload_table_name, autorun) 437 print(f"Saving error to: {suitableOutputFile}") 438 self.connHandler.dump_to_file(suitableOutputFile, 439 response) --> 440 raise requests.exceptions.HTTPError(response.reason) 441 else: 442 location = self.connHandler.find_header( 443 response.getheaders(), 444 "location")

HTTPError: OK

jvines commented 2 years ago

Gaia servers might be down.

Nothing I can do in my end.