On second thought, an easier alternative is to just throw an exception if either the dataset or the model are not ready, and make that a precondition: if the user of the API wants to wait for them, she knows how to do it, and can do it in any way suits her better.  And we make this function simpler....