AstroPy solves for leap seconds  according to the IAU ERFA (SOFA) library  and the IERS-B and IERS-A tables . IERS-B tables ship with AstroPy. The latest IERS-A tables ("from 1973 though one year into the future") auto-download on first use .
I've just tried it. Unfortunately, it does not seem to be compatible with PEP 495 datetime yet:
>>> t = astropy.time.Time('2016-12-31T23:59:60')
Traceback (most recent call last):
ValueError: Time (array(2016, dtype=int32), array(12, dtype=int32), array(31, dtype=int32), array(23, dtype=int32), array(59, dtype=int32), array(60, dtype=int32), array(0, dtype=int32)) is within a leap second but datetime does not support leap seconds
Maybe someone can propose a feature for astropy to return datetime(2016,12,31,23,59,59,fold=1) in this case.
 "Leap second day utc2tai interpolation"