aiidateam / aiida-cp2k

The CP2K plugin for the AiiDA workflow and provenance engine.
https://aiida-cp2k.readthedocs.io/en/latest/
MIT License
23 stars 28 forks source link

Adding a extra condition to restart_incomplete_calcution #179

Closed AndresOrtegaGuerrero closed 1 year ago

AndresOrtegaGuerrero commented 1 year ago

The new conditions ask for the end of SCF inner cycle with "Total energy:", This guarantees that there is *.wfn file in the directory

AndresOrtegaGuerrero commented 1 year ago

I restored the initial conditions (remove my changes) , but somehow is not working , I get an error 402 (which i dont find). I assume now it should pass the test in github, yet i need to work on the solution

AndresOrtegaGuerrero commented 1 year ago

The issue seems that the example_base_failed_restart.py , checks if the process exit_status is 400, however, there could be the case that in the first restart it successfully completes the calculation, then the exit code is 0 for the workchain , or is 402 which means that 2 attempts were not enough to complete the simulations. I include a modification to check the first calcjob to check if the restart is handled.