More work will be necessary to carry through the extra precision
everywhere, but this is a start that addresses the most visible
manifestation of the previously low precision.
It was awkward to hide the ability to create times from the Julian day
behind the very last argument in the time constructor argument lists.
Let’s start moving in a better direction that makes the ability more
discoverable, and starts to backtrack on one of those awkward situations
where half the arguments to a given method are always useless.
Fixes #181.
* Added tests to cover issues (delta_t calculation, and __repr__ output).
* Added a fix to the array Time.__repr__ issue (now gives a similar format to skyfield.units.Angle)
* Added fix for future scalar delta_t issue.
This improvement removes the apparent redundancy from a statement like:
jd = ts.tt(jd=value)
(why are the raw value and the object both named `jd`, a user might
wonder?) and also hopefully makes it less likely that new users will
think that a `JulianDate` object specifies merely a date but not also a
specific time.
I got tired of seeing so many double parentheses in calls like
`ts.utc((1980, 2, 3))` and so I am pivoting away from tuple arguments
and towards separate date components for the timescale methods, so the
calls read like `ts.utc(1980, 2, 3)` instead.
It makes more sense to have the `Loader` know everything about how to
download the correct files from the Internet, rather than having the
Timescale know internally how to fetch its data.
My initial idea had been that all date-time methods ought to return
leap-second indicators, so that the fact of leap seconds would be
obvious to all users asking for dates, and I would not get as many
questions about apparent discontinuities when users generate close time
series that cross leap-second boundaries.
But on the twenty or thirty different occasions on which I have needed
utc_datetime() so far, I myself have *always* forgotten about the second
return value and have *never* remembered to prepare for it. So I am
changing these methods to do the obvious thing that users will expect,
and making alternative versions of them for users who care about leap
seconds.