Don't show pending jobs among the already finished

Not tested because I am not able to setup
the environment :-(