I ran into a very weird bug with fs.copyFileSync. at the end of the copy call, I check the size of source and destination and sometimes, the sizes do not match!
here