AstroPy solves for leap seconds [1][2] according to the IAU ERFA (SOFA) library [3] and the IERS-B and IERS-A tables [4]. IERS-B tables ship with AstroPy. The latest IERS-A tables ("from 1973 though one year into the future") auto-download on first use [5].

[1] http://docs.astropy.org/en/stable/time/#time-scales-for-time-deltas
[2] http://docs.astropy.org/en/stable/time/#writing-a-custom-format
[3] "Leap second day utc2tai interpolation"
https://github.com/astropy/astropy/issues/5369
[4] https://github.com/astropy/astropy/pull/4436
[5] http://docs.astropy.org/en/stable/utils/iers.html


On Thursday, May 17, 2018, Alexander Belopolsky <alexander.belopolsky@gmail.com> wrote:


On Thu, May 17, 2018 at 3:13 PM Tim Peters <tim.peters@gmail.com> wrote:
[Chris Barker]
> Does that support the other way -- or do we never lose a leap second anyway?
> (showing ignorance here)

Alexander covered the Python part of this,  ...

No, I did not.  I did not realize that the question was about skipping a second instead of inserting it.  Yes, regardless of whether it is possible given the physics of Earth rotation, negative leap seconds can be supported.  They simply become "gaps" in PEP 495 terminology.  Check out PEP 495 and read "second" whenever you see "hour". :-)