set

erfa.leap_seconds.set(table=None)[source]

Set the ERFA leap second table.

Note that it is generally safer to update the leap-second table than to set it directly, since most tables do not have the pre-1970 changes in TAI-UTC that are part of the built-in ERFA table.

Parameters:
tablearray_like or None

Leap-second table that should at least hold columns of ‘year’, ‘month’, and ‘tai_utc’. Only simple validation is done before it is being used, so care need to be taken that entries are correct. If None, reset the ERFA table to its built-in values.

Raises:
ValueError

If the leap seconds in the table are not on the 1st of January or July, or if the sorted TAI-UTC do not increase in increments of 1.