def METHOD_NAME(cls, limit: int) -> Sequence[JobModel]:
    """Gets at most `limit` unfinished jobs.
    Args:
        limit: int. A limit on the number of jobs to return.
    Returns:
        list(JobModel) or None. A list of at most `limit` number
        of unfinished jobs.
    """
    return cls.query().filter(
        JobModel.status_code.IN([STATUS_CODE_QUEUED, STATUS_CODE_STARTED])
    ).order(-cls.time_queued_msec).fetch(limit)