-
Notifications
You must be signed in to change notification settings - Fork 52
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
Keep same extension when created tmp config file #885
base: develop
Are you sure you want to change the base?
Conversation
The users script may not work properly if the config file does not have the expected extension. We should keep the same one instead of turning it into .conf.
|
||
assert original_ext == tmp_ext | ||
|
||
shutil.rmtree(trial.working_dir) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is it necessary to do this? Shouldn't the working directory in the config always be based on the temp_path
fixture?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's because of this line: https://github.com/Epistimio/orion/pull/885/files#diff-5fe3b7fe336f5a8a566e677336db8fc5f708b6da4e5662fef48c7bfc95fc1c42R34. We could perhaps convert it to temp_path
.
@@ -197,9 +194,16 @@ def get_execution_environment(self, trial, results_file="results.log"): | |||
|
|||
return env | |||
|
|||
def _consume(self, trial, workdirname): | |||
def _prepare_config(self, trial, workdirname): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: I know your stance is to add type hints to new modules, but I think new methods might also be a good opportunity to add type hints.
Must adapt doc after merging #957 |
The users script may not work properly if the config file does not have the expected extension. We should keep the same one instead of turning it into .conf.
@hnekoeiq