aiida-core icon indicating copy to clipboard operation
aiida-core copied to clipboard

`StashCalculation` does not wait until specified CalcJob finished

Open agoscinski opened this issue 6 months ago • 2 comments

Start some CalcJob and a StashCalculation using source list = ['*'], then the StashCalculation will not wait until the CalcJob finished.

agoscinski avatar Jun 11 '25 09:06 agoscinski

Ok, I see. Probably this happens, because RemoteFolder is created and exist before the calcjob finish... We could solve this, knowing which calcjob is linked to that RemoteFolder, how to do this in aiida?

khsrali avatar Jun 11 '25 14:06 khsrali

@khsrali I think that you should be able to use the creator attribute of the RemoteData or RemoteFolder (https://github.com/aiidateam/aiida-core/blob/main/src/aiida/orm/nodes/data/data.py#L125C9-L125C16) which would return the CalcJob and one could easily check whether it has already finished

t-reents avatar Jun 11 '25 14:06 t-reents