Look for bowtie in program:, not bowtie2.
Copy dictionary before modifying it.