Writing to /tmp/tseemann/bcftools.8KmiHW
Merging 1 temporary files
Done
Cleaning
<snip>
OSError: [Errno 18] Invalid cross-device link: '/tmp/tseemann/tmpgyndfdtn/temp.sorted.vcf.gz' -> '/home/tseemann/test2/test/neat_sim_golden.vcf.gz'
My /tmp is a different drive to my /home.
I assume the code is trying to mv but that can't work across filesystems.
Can you use cp+rm instead? Via os.copy() ?