prepping the migration of some joined_paired_ends.py code into format.py