The meat of this commit is to implement T602 - moving a lot of
the 'jobs for specific compose' logic out of the CLI module
into the schedule module, allowing for non-CLI consumers to use
it. There are various related changes bundled in.
Most significantly, 'ifnotcurrent' is replaced with a 'force'
argument that's shared by most of the schedule functions - they
all ultimately pass it to run_openqa_jobs(), which handles it.
If force is false-y, jobs will not be scheduled if there are
any existing, non-cancelled jobs for the given ISO and flavor.
This fulfills the same basic goal as 'ifnotcurrent' - making
sure scheduled nightly and current runs won't schedule jobs for
the same compose - while avoiding the need to hit up the wiki
(and hence meaning jobs_from_compose() does not need the wiki
at all) and being more generally useful, I think.
We now need the wiki only for two things: jobs_from_current()
(to find what the 'current' compose *is*) and, obviously, result
reporting.
There's a more minor change to how arches are handled. The
ARCHES constant is a tuple not a list now (I did this because
it was the default value for an optional function argument and
those shouldn't be mutable; then I made it not the default
value any more, but keeping it as a tuple seems appropriate
anyway). jobs_from_fedfind() has arches=None as the default
and takes the list from the constant if arches isn't set; that
lets us clean things up in cli.py rather a bit.
There's a bit of a bugfix in the CLI to job reporting - we
weren't passing in the CLI wiki object or 'submit' value
properly for 'current' or 'compose', only for 'report'. I also
tried to clean up the logging a bit in general.