[7450] in SIPB bug reports
NEW PROJECT: sunrise/sunset, OR y2k problem in sipb locker
daemon@ATHENA.MIT.EDU (chad brown)
Thu Dec 16 11:26:13 1999
Date: Thu, 16 Dec 1999 16:24:12 GMT
Message-Id: <199912161624.QAA04345@egon.jyrc.org>
From: chad brown <chad@akamai.com>
To: bug-sipb@MIT.EDU, sipb-office@MIT.EDU
Cc: cordelia@MIT.EDU, jik@MIT.EDU
The sipb locker contains a program called `sdate', that can be used to
determine the time of sunrise or sunset of a particular day. This
program is from the comp.unix.sources archive, and is several years
old.
The canonical version in the archives does not accept a date argument;
it always reports on the sunrise and sunset times for what the system
believes to be the current day. The sipb locker version makes use of
a function called get_date() (Hi, Matthew!) to allow a date argument
to be passed in instead.
This function does not accept dates after 31 Dec 1999, apparently. It
is totally missing from the `canonical' version mentioned in the
WHERETOGETIT file, and is defined in
/afs/sipb/project/sipbsrc/src/sdate, but not
/afs/sipb/project/sipb/src/sdate (that is, it's in sipbsrc, but not in
sipb/src). It was apparently placed there by me, in 1994, although
jik is also implicated. It *also* contains a `STATUS' file that
contains the single line: ``broken. Local time is off. Odd.'' (I
vaugely remember finding this problem).
So, obviously, the state of the ``sipb locker program to find the time
of sunrise or sunset'' is pretty messy, and should be clened up. Here
are some options:
* We could remove the program from the sipb locker, and tell users to
use the web to find this information. We could even hack together a
script or link or something to point them at a good place for
finding this information.
** This is the path that I will take, because it's easy, and I've
already spent more time on it than my laziness allows. Someone
else should feel encouraged to instead/addionally follow one of
the following options.
* Someone could fix the getdate.y in sipbsrc/src/sdate to deal with
dates in the next millennium (plus maybe the year before that).
This person should also attempt to determine why that version is
labelled as `broken'.
* We could replace the packge with a totally different package. I
just spent a short while looking and was a bit discouraged.
I did find a package called `ephem' at
http://www.drwren.com/ephem/ that was meant to take some
uninteresting sunrise/sunset calculations and make them jump
through some hoops resulting in X10 home automation tricks. The
calculation code was (paraphrased) ``taken from some BASIC code
from a 1994 edition of Sky and Telescope Magazine''. It does not
accept a day option, and it seems to give results slightly
different from sdate (by roughly 1 minute, today).
/mit/sipb/src/ephem-0.20
I found a package called `skycal' that's really intended more for
astonomers doing advanced planning; its output is the table for
each day in a given year. On the other hand, it's at least C
code.
/mit/sipb/src/skycal.tar.gz (unpacks in cwd)
Lastly, I found a package called `remind', which claims to be:
``Full-featured calendar/reminder program featuring sophisticated
date calculation, moon phases, sunrise/sunset, Hebrew calendar,
alarms, PostScript output, X-Windows front-end, multilingual
messages, and proper handling of holidays.'' This is probably the
most promising entry, although I have not yet waded through it's
`full features' enough to tell if it's likely to work.
/mit/sipb/src/remind-03.00.20, installed for sun in outland