BAIT: accepter command

NAME

accepter - to check the syntax of a request file

SYNOPSIS

accepter request_file [privilege] [verbose] [date=dd/mm/yyyy]

DESCRIPTION

The accepter program reads each line of the request file on the command line and looks for errors in the syntax or cases that exceed the capabilities of the telescope. It checks the values of most of the keywords described in `request.man' and reports if they have invalid values (e.g. a negative exposure time). When an error is found the program writes lines like:

DEC limit exceeded .. -44.09 is below -28.00 degs PRIORITY value 0 is < min value 1

where the offending keyword appears first and some hint of the problem is printed to stdout. The program will then exit with a non-zero status code.

The telescope capabilities are taken from the file $HOME_DIR/ ait.config, where HOME_DIR must be specified in the environment.

The accepter makes no comment about keywords that it doesn't understand, unless the `verbose' command line switch is used.

If the request file passes through the elementary value and syntax checking part, it then checks for the presence of keywords needed by insgen (the telescope scheduling program) and finally checks the values of the PROCEDUR statement with known programs. The accepter issues an error message for unknown procedures. For known procedures it will check that the required keywords are set.

The accepter will generate error messages when certain keyword values used by insgen are altered in subsequent stanzas. These keywords are DAYSTART, DAYEND, NUM-OBS, UTSTART, LSTSTART, LSTEND, REQID, PRIORITY, INTERVAL, JDSTART, and NUMPERNI.

An error message will be generated if the REQID does not match the filestem of the filename.

For observations that contain an RA ,DEC and EPOCH the accepter will see whether the target can be observed while the sun is at most 12 degrees below the horizon. It will assume the current date or DAYSTART if specified. If the observing window is too small (or non-existent) or the target is too close to the moon an error message will be printed and the target rejected. If a UT-START is specified, with the coordinates, observations can be made if the sun is below +10 degrees above the horizon.

OPTIONS

privilege - some priority values can only be executed by privileged users. The accepter will generate error messages if this flag is not specified.

verbose - prints remarks to stdout concerning keywords that it does not recognized. These remarks do not influence the final exit code. It also flags duplicate END statements.

date= - allows you to test the accepter for running on other dates.

BUGS

The acceptable procedures and their required keywords should appear in a file rather than be compiled into the program.

If an error is found, it is re-iterated for every stanza in the file.

If a keyword has an improper value like an improper string format, other errors in the request file such as bad DAYSTART or missing FILTERS will not be found.

SEE ALSO>

insgen, request, ait.config