Moved parse_priority to utils.py.