As I might not know the name of the file. Would this example work?
Otherwise i guess i might dynamically look into the remote tree and pick the names, although less convenient.
Thanks a lot for any pointer!
Thanks Sebastiaan! I tried it out but unfortunately it doesn’t work, as it requires to specify 3 strings (so None is not accepted), and at the same time it doesn’t accept glob patterns for the last string (as it stop throwing out a related error saying that). I am working with aiida-core v2.3.1, so don’t know if there is any new functionality that allows to do so - otherwise, it seems that one cannot use wildcards for the remote copy list right now.
Did you try to specify a folder for the last (destination) path, as you would do with cp? Try with a subfolder of the scratch that you should create beforehand (this should work, I think?) and then also with . if you want to copy in to the main scratch folder of the job (there is a small probability that the latter does not work, in which case it’s a bug and we should fix it).