-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
experiment should only need one wait_on_done method #2037
Comments
Let's document what changes should be done here, discuss the impact, how we manage downstream impacts, communication etc |
Steps to do the fix:
You then check the run_opts and if wait_on_done exists, tell the user it will be deprecated on a release scheduled for X(one month out)? def run(self, wait_until_done: bool = False, platform: 'IPlatform' = None, regather_common_assets: bool = None,
wait_on_done_progress: bool = True,
**run_opts) -> NoReturn:
"""
Runs an experiment on a platform.
Args:
wait_until_done: Whether we should wait on experiment to finish running as well. Defaults to False
platform: Platform object to use. If not specified, we first check object for platform object then the current context
regather_common_assets: Triggers gathering of assets for *existing* experiments. If not provided, we use the platforms default behaviour. See platform details for performance implications of this. For most platforms, it should be ok but for others, it could decrease performance when assets are not changing.
It is important to note that when using this feature, ensure the previous simulations have finished provisioning. Failure to do so can lead to unexpected behaviour
wait_on_done_progress: Should experiment status be shown when waiting
**run_opts: Options to pass to the platform
Returns:
None
"""
if 'wait_on_done' in run_opts:
warnings.warn("wait_on_done will be deprecated in the next release. Please change to <>")
|
Ensure we inform @tfischle-idmod @jonathanhhb @stitova-idm and other stakeholders of this change. Ensure emodpy examples are updated. Check in with existing researchers as well(most likely these are all one line errors, but having documentation on how it will be fixes is useful) e = Experiment()
e.run(wait_until_on=True) |
Verify repos that use idmtools what is best parameter to drop(ie, https://github.com/search?q=repo%3AInstituteforDiseaseModeling%2Femodpy+wait_on_done&type=code vs https://github.com/search?q=repo%3AInstituteforDiseaseModeling%2Femodpy%20wait_until_done&type=code) |
there are 265 files for "wait_until_done=" and 105 files for "wait_on_done=" cross InstituteforDiseaseModeling. I think we should drop wait_on_done. For first time change, I am just going to print warning message |
Currently we have to use both at same time with wait_on_done and wait_until_done with False case. This is useful with dry_run=True.
We should change to allow only one wait.
The text was updated successfully, but these errors were encountered: