Dear all,
I am writing as I am not sure how to solve the problem I am facing. The test test_run of the file workflows/test_ase.py of aiida-phonopy is failing with the following error:
test_ase.py::test_run 07/15/2025 09:06:04 AM <55310> aiida.orm.nodes.process.workflow.workchain.WorkChainNode: [REPORT] [25|PhonopyAseWorkChain|run_forces]: submitting `PythonJob` <PK=31> with supercell n.o 1
07/15/2025 09:06:06 AM <55310> aiida.orm.nodes.process.workflow.workchain.WorkChainNode: [REPORT] [25|PhonopyAseWorkChain|run_phonopy]: submitting `PhonopyCalculation` <PK=40>
07/15/2025 09:06:07 AM <55310> aiida.engine.transports: [ERROR] Exception whilst using transport:
Traceback (most recent call last):
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/transports.py", line 106, in request_transport
yield transport_request.future
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/processes/calcjobs/tasks.py", line 372, in do_stash
return await execmanager.stash_calculation(node, transport)
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/daemon/execmanager.py", line 455, in stash_calculation
target_base = Path(stash_options['target_base'])
KeyError: 'target_base'
07/15/2025 09:06:07 AM <55310> aiida.orm.nodes.process.calculation.calcjob.CalcJobNode: [ERROR] iteration 1 of do_stash excepted, retrying after 20 seconds
Traceback (most recent call last):
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/utils.py", line 205, in exponential_backoff_retry
result = await coro()
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/processes/calcjobs/tasks.py", line 372, in do_stash
return await execmanager.stash_calculation(node, transport)
File "/opt/conda/lib/python3.10/site-packages/aiida/engine/daemon/execmanager.py", line 455, in stash_calculation
target_base = Path(stash_options['target_base'])
KeyError: 'target_base'
I honestly don’t understand why, as it was not happening before. I guess something has changed with the InstalledCode.
Sounds like we have a bug. @bastonero can you please specify what’s the workflow you’re running?
If it includes stashing operation through metadata.option.stash
or
it uses something like calc_info.skip_submit = True in the workflow.
I really don’t understand how’s this happening
Somehow task_stash_job is being called, while you don’t have any stash or whatsoever defined.
This should not happen, because we already have a measure for that:
I feel like, this bug is induced by plumpy magical hands
To examine that, can try to see if you can reproduced it with this possible fix I just pushed: 515a6fb
Edit try this branch instead:
Please let me know if this works!
Cheers and sorry for the inconvenience!
Ali
Perfect!
Thanks @bastonero, we’ll soon release 2.7.1 with this fix.
In the end, it sees task_stash_job is being triggered even though no stash options are defined.
The reason appeared to be that sometimes node.get_option('stash') returns an empty dictionary instead of None. Which the reason of that itself is unknown to us.
Our guess is that, It has something to do with way builder stores that info.
To be investigated, – of course this is independent to the patch release!