if it is None, then it is a bug, and we should throw an exception. I should have added a comment here.