BibSched: improve sequenceid handling
- Fixes some bugs where the sequenceid was not considered in the Python code.
- Adds MySQL index for sequenceid.
- When handling several tasks with the same sequenceid, raise their priority to the maximum priority among them (so that the taskid order is still respected).
- Don't consider None as a sequenceid.