Skip to content

Commit

Permalink
Fix for "Reader argument to ascii.read was deprecated" warning (#165)
Browse files Browse the repository at this point in the history
* Fix for "Reader argument to ascii.read was deprecated" warning
  • Loading branch information
javierggt authored Feb 2, 2024
1 parent 3cc75c8 commit 1d6dd75
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions agasc/tests/test_agasc_2.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
def get_ds_agasc_cone(ra, dec):
cmd = "mp_get_agasc -r {!r} -d {!r} -w {!r}".format(ra, dec, TEST_RADIUS)
lines = Ska.Shell.tcsh(cmd, env=ascds_env)
dat = ascii.read(lines, Reader=ascii.NoHeader, names=AGASC_COLNAMES)
dat = ascii.read(lines, format="no_header", names=AGASC_COLNAMES)

ok1 = agasc.sphere_dist(ra, dec, dat["RA"], dat["DEC"]) <= TEST_RADIUS
ok2 = dat["MAG_ACA"] - 3.0 * dat["MAG_ACA_ERR"] / 100.0 < 11.5
Expand Down Expand Up @@ -362,7 +362,7 @@ def mp_get_agascid(agasc_id):
cmd = "mp_get_agascid {!r}".format(agasc_id)
lines = Ska.Shell.tcsh(cmd, env=ascds_env)
lines = [line for line in lines if re.match(r"^\s*\d", line)]
dat = ascii.read(lines, Reader=ascii.NoHeader, names=AGASC_COLNAMES)
dat = ascii.read(lines, format="no_header", names=AGASC_COLNAMES)

return dat

Expand Down
1 change: 1 addition & 0 deletions dev/profile_cache.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Profile performance of get_agasc_cone with and without cache"""

import time
from pathlib import Path

Expand Down

0 comments on commit 1d6dd75

Please sign in to comment.