When one of the files in the folder pointed by archiveArtifacts has not the read bit set, the function crashes without explanation.
Expected:
An error message telling that not all files could be archived due to a missing read flag.
This took over a month of research to find the issue at hand.