WIP get_next_task