Skip to content

Commit 81752a5

Browse files
committed
Fix astropy#9206 by making IERS B use deterministic
IERS_Auto merges in columns from the IERS B table. But as it stood, the version of IERS B that was used was difficult to control. Now it always uses the version built in to astropy.
1 parent bb02bb5 commit 81752a5

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

‎astropy/utils/iers/iers.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -824,7 +824,7 @@ def _substitute_iers_b(cls, table):
824824
Here, we use the bundled astropy IERS-B table to overwrite the values
825825
in the downloaded IERS-A table.
826826
"""
827-
iers_b = IERS_B.open()
827+
iers_b = IERS_B.open(IERS_B_FILE)
828828
# Substitute IERS-B values for existing B values in IERS-A table
829829
mjd_b = table['MJD'][np.isfinite(table['UT1_UTC_B'])]
830830
i0 = np.searchsorted(iers_b['MJD'], mjd_b[0], side='left')

‎astropy/utils/iers/tests/test_iers_b_into_auto.py‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ def test_IERS_B_parameters_loaded_into_IERS_Auto_correctly(
105105
b_name,
106106
a_name,
107107
atol):
108+
IERS_Auto.iers_table = None
108109
A = IERS_Auto.open()
109110
A[a_name]
110111
B = IERS_B.open(IERS_B_FILE)

0 commit comments

Comments
 (0)