Open ryotatomioka opened 1 year ago
@ryotatomioka Thanks for the repro and great analysis!
+1 for making self.vasp_cmd
and self.gamma_vasp_cmd
immutable.
Good catch @ryotatomioka , and sorry for messing this up. I tried to stick to the old terminate functionality, but messed up at least one indentation. Maybe more.
@janosh , I am happy to make the commands immutable in a PR, but probably this can be included in #264, since this also has to do with termination. What do you think?
@MichaelWolloch Yes, if @fyalcin would like to include a fix for this in #264, that'd be great!
@shyuep I think this was closed in #264.
When reporting bugs/issues, please supply the following information. If this is a feature request, please simply state the requested feature.
System
Summary
I believe a bug was introduced in this commit around these lines https://github.com/materialsproject/custodian/blob/f7dc11a15aee43e57cc8b52bf4a39ed7c5fd1e63/custodian/vasp/jobs.py#L689-L696
The problem is that both
self.vasp_cmd
andself.gamma_vasp_cmd
can be lists! In this case,self.gamma_vasp_cmd
is appended toself.vasp_cmd
every timeterminate
method is called. This is the case whencustodian
is called fromatomate2
. See: https://github.com/materialsproject/atomate2/blob/02e44c038903d2c935c82b31afd8ab82a69c039e/src/atomate2/vasp/run.py#L86-L170This results in
For some reason, custodian does not see this as an error and keep applying the same correction until the maximum number of corrections are used resulting in a confusing error message. It would be better if we can improve the error message as well.
Example code
Error message
Suggested solution (if known)
Files
<If input files are needed for the error, please copy and paste them here.>