Skip to content

Commit f73ad59

Browse files
volodymyrssbsipocz
authored andcommitted
trying to avoid duplication between remote/local tests
1 parent cafc323 commit f73ad59

21 files changed

+6996
-14
lines changed

astroquery/heasarc/core.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ def query_mission_cols(self, mission, cache=True, get_query_payload=False,
8787
All other parameters have no effect
8888
"""
8989

90-
response = self.query_region_async(position=coordinates.SkyCoord(0.0, 0.0, unit='deg'),
90+
response = self.query_region_async(position=coordinates.SkyCoord(10, 10, unit='deg', frame='fk5'),
9191
mission=mission,
9292
radius='361 degree',
9393
cache=cache,
@@ -191,7 +191,7 @@ def _old_w3query_fallback(self, content):
191191
f.writeto(I)
192192
I.seek(0)
193193

194-
return Table.read(I)
194+
return Table.read(I, unit_parse_strict='silent')
195195

196196
def _fallback(self, text):
197197
"""
@@ -221,8 +221,9 @@ def _fallback(self, text):
221221
new_table.append("".join(newline))
222222

223223
data = StringIO(text.replace(old_table, "\n".join(new_table)))
224-
return Table.read(data, hdu=1)
224+
return Table.read(data, hdu=1, unit_parse_strict='silent')
225225

226+
226227
def _parse_result(self, response, verbose=False):
227228
# if verbose is False then suppress any VOTable related warnings
228229
if not verbose:
@@ -242,7 +243,7 @@ def _parse_result(self, response, verbose=False):
242243

243244
try:
244245
data = BytesIO(response.content)
245-
table = Table.read(data, hdu=1)
246+
table = Table.read(data, hdu=1, unit_parse_strict='silent')
246247
return table
247248
except ValueError:
248249
try:

astroquery/heasarc/tests/data/0f36aba7.dat

Lines changed: 1001 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
SIMPLE = T / BROWSE (FITSDISPLAY V0.1) BITPIX = 8 NAXIS = 0 / DUMMY HDU EXTEND = T / EXTENSIONS ALLOWED END XTENSION= 'TABLE ' / ASCII TABLE EXTENSION BITPIX = 8 / MANDATORY VALUE NAXIS = 2 / MANDATORY VALUE NAXIS1 = 84 / LENGTH OF ROW NAXIS2 = 63 / NUMBER OF ROWS PCOUNT = 0 / MANDATORY VALUE GCOUNT = 1 / MANDATORY VALUE TFIELDS = 7 / NUMBER OF FIELDS EXTNAME = 'ROSMASTER' / EXTENSION NAME TABLE = 'HEASARC_ROSMASTER' / TABLE DESIGNATOR TAB_DESC= 'ROSAT ARCHIVAL DATA' TAB_URL = 'HTTPS://HEASARC.GSFC.NASA.GOV/W3BROWSE/ROSAT/ROSMASTER.HTML' TTYPE1 = 'SEQ_ID' TFORM1 = 'A11 ' TBCOL1 = 1 TTYPE2 = 'INSTRUMENT' TFORM2 = 'A10 ' TBCOL2 = 13 TTYPE3 = 'EXPOSURE' TFORM3 = 'I8 ' TUNIT3 = 'S' TBCOL3 = 24 TTYPE4 = 'RA' TFORM4 = 'F8.0 ' TUNIT4 = 'DEGREE' TDISP4 = 'F8.4' TBCOL4 = 33 TTYPE5 = 'DEC' TFORM5 = 'F6.0 ' TUNIT5 = 'DEGREE' TDISP5 = 'F6.4' TBCOL5 = 42 TTYPE6 = 'NAME' TFORM6 = 'A20 ' TBCOL6 = 49 TTYPE7 = 'SEARCH_OFFSET_' TFORM7 = 'A14 ' TBCOL7 = 70 END RH701576N00 HRI 68154 187.2800 2.0500 3C 273 0.190 (3C273)
2+
RP600242A01 PSPCB 24822 186.9300 1.6000 GIOVANELLI-HAYNES CL 34.236 (3C273)
3+
RH700234N00 HRI 17230 187.2800 2.0500 3C 273 0.190 (3C273)
4+
RP700191N00 PSPCB 6140 187.2700 2.0500 3C273 0.496 (3C273)
5+
RH702682N00 HRI 4896 187.2700 2.0500 3C 273 0.496 (3C273)
6+
RH702681N00 HRI 4416 187.2700 2.0500 3C 273 0.496 (3C273)
7+
RH702684N00 HRI 4105 187.2700 2.0500 3C 273 0.496 (3C273)
8+
RH702680N00 HRI 4063 187.2700 2.0500 3C 273 0.496 (3C273)
9+
RH702683N00 HRI 3986 187.2700 2.0500 3C 273 0.496 (3C273)
10+
RH702679N00 HRI 3662 187.2700 2.0500 3C 273 0.496 (3C273)
11+
RP141509N00 PSPCB 3330 187.2700 2.0500 3C273 0.496 (3C273)
12+
RF700191N00 PSPCB 3279 187.2700 2.0500 3C273 0.496 (3C273)
13+
RP600242N00 PSPCB 3078 186.9300 1.6000 GIOVANELLI-HAYNES CL 34.236 (3C273)
14+
RH702678N00 HRI 2866 187.2700 2.0500 3C 273 0.496 (3C273)
15+
RH701661N00 HRI 2702 187.2800 2.0500 3C 273 0.190 (3C273)
16+
RH701966N00 HRI 2652 187.2800 2.0500 3C273 0.190 (3C273)
17+
RH702677N00 HRI 2424 187.2700 2.0500 3C 273 0.496 (3C273)
18+
RH701975N00 HRI 2209 187.2800 2.0500 3C273 0.190 (3C273)
19+
RH701973N00 HRI 2176 187.2800 2.0500 3C273 0.190 (3C273)
20+
RH701961N00 HRI 2088 187.2800 2.0500 3C273 0.190 (3C273)
21+
RH701963N00 HRI 2053 187.2800 2.0500 3C273 0.190 (3C273)
22+
RH701962N00 HRI 2019 187.2800 2.0500 3C273 0.190 (3C273)
23+
RP701256N00 PSPCB 2002 187.2800 2.0500 3C273 0.190 (3C273)
24+
RP701269N00 PSPCB 1974 187.2800 2.0500 3C273 0.190 (3C273)
25+
RP701255N00 PSPCB 1973 187.2800 2.0500 3C273 0.190 (3C273)
26+
RP701268N00 PSPCB 1970 187.2800 2.0500 3C273 0.190 (3C273)
27+
RH701968N00 HRI 1931 187.2800 2.0500 3C273 0.190 (3C273)
28+
RH701969N00 HRI 1889 187.2800 2.0500 3C273 0.190 (3C273)
29+
RP701267N00 PSPCB 1874 187.2800 2.0500 3C273 0.190 (3C273)
30+
RH701976N00 HRI 1866 187.2800 2.0500 3C273 0.190 (3C273)
31+
RH701970N00 HRI 1864 187.2800 2.0500 3C273 0.190 (3C273)
32+
RP701266N00 PSPCB 1840 187.2800 2.0500 3C273 0.190 (3C273)
33+
RH701957N00 HRI 1831 187.2800 2.0500 3C273 0.190 (3C273)
34+
RH701964N00 HRI 1823 187.2800 2.0500 3C273 0.190 (3C273)
35+
RH701960N00 HRI 1815 187.2800 2.0500 3C273 0.190 (3C273)
36+
RP701265N00 PSPCB 1784 187.2800 2.0500 3C273 0.190 (3C273)
37+
RH701959N00 HRI 1751 187.2800 2.0500 3C273 0.190 (3C273)
38+
RP701260N00 PSPCB 1744 187.2800 2.0500 3C273 0.190 (3C273)
39+
RH701971N00 HRI 1720 187.2770 2.0519 3C273 0.062 (3C273)
40+
RP701264N00 PSPCB 1705 187.2800 2.0500 3C273 0.190 (3C273)
41+
RH701956N00 HRI 1704 187.2800 2.0500 3C273 0.190 (3C273)
42+
RH701958N00 HRI 1659 187.2800 2.0500 3C273 0.190 (3C273)
43+
RH701965N00 HRI 1644 187.2800 2.0500 3C273 0.190 (3C273)
44+
RH701955N00 HRI 1586 187.2800 2.0500 3C273 0.190 (3C273)
45+
RH701972N00 HRI 1563 187.2800 2.0500 3C273 0.190 (3C273)
46+
RH701953N00 HRI 1533 187.2800 2.0500 3C273 0.190 (3C273)
47+
RH701967N00 HRI 1511 187.2800 2.0500 3C273 0.190 (3C273)
48+
RP701263N00 PSPCB 1503 187.2800 2.0500 3C273 0.190 (3C273)
49+
RH701257N00 HRI 1473 187.2800 2.0500 3C273 0.190 (3C273)
50+
RH701954N00 HRI 1373 187.2800 2.0500 3C273 0.190 (3C273)
51+
RP701262N00 PSPCB 1324 187.2800 2.0500 3C273 0.190 (3C273)
52+
RH701952N00 HRI 1189 187.2800 2.0500 3C273 0.190 (3C273)
53+
RP701261N00 PSPCB 1122 187.2800 2.0500 3C273 0.190 (3C273)
54+
RP701259N00 PSPCB 1048 187.2800 2.0500 3C273 0.190 (3C273)
55+
RP701258N00 PSPCB 1040 187.2800 2.0500 3C273 0.190 (3C273)
56+
RH701974N00 HRI 982 187.2800 2.0500 3C273 0.190 (3C273)
57+
RP120000N00 PSPCC 916 187.2700 2.0500 XRT/PSPC NORTH DUMMY 0.496 (3C273)
58+
RH141520N00 HRI 765 187.2700 2.0500 3C273 0.496 (3C273)
59+
RH701978N00 HRI 671 187.2800 2.0500 3C273 0.190 (3C273)
60+
RH701981N00 HRI 498 187.2800 2.0500 3C273 0.190 (3C273)
61+
RP141520N00 PSPCB 485 187.2700 2.0500 3C273 0.496 (3C273)
62+
RH701979N00 HRI 354 187.2800 2.0500 3C273 0.190 (3C273)
63+
RH120001N00 HRI 0 187.2700 2.0500 XRT/HRI NORTH DUMMY 0.496 (3C273)
64+

0 commit comments

Comments
 (0)