Lease requests get blocked by top priority jobs with unmeetable requirements
Context
The work done in !181 (merged) to support bots long-polling when requesting work switched to using a PriorityQueue internally to represent the job queue, rather than a list. This made the logic for blocking for a given amount of time simple, but inadvertently introduced a limitation whereby we no longer iterate to find a runnable job if the highest priority job is invalid for a given worker (unmet requirements for example).
This limitation means that the entire BuildGrid instance can get blocked from executing any work by a job which by accident or design cannot be given to any of the worker machines. Such a job will always be retrieved ahead of actually doable work of a lower priority, and will get ignored and re-enqueued when it can't be executed. Since we no longer iterate, the worker will receive no work and repeat the request with the same results.
Some work will likely get done with enough workers and/or lucky timing, since the problematic job is temporarily not in the queue whilst the capability check is made, but we really shouldn't rely on this. If BuildGrid gets into this situation it should be easy to resolve by simply cancelling the problematic job, which will cause it to be dropped from the queue, but it is better to not get stuck in the first place.
Acceptance Criteria
Impossible jobs can be enqueued with high priority with negligible effect on the ability of BuildGrid to function.