intbio-ncl / BiomationScripterLib

A Python library to assist with scripting bio-automation protocols
MIT License
3 stars 0 forks source link

Transformation prints incorrect locations when shuffled #42

Closed davidcmarkham closed 2 years ago

davidcmarkham commented 2 years ago

Heat_Shock_Transformation Template in OTProto has a print statement that sends potentially wrong infomration to the user.

Line 350 (at time of raising this issue)

        # TODO: This mapping is incorrect, pls fix it #
        print("Transformation Mapping")
        for dna, destination in zip([f"{layout.name}: {layout.get_liquids_in_well(well)[0]} ({well})" for layout in self.dna_source_layouts for well in layout.get_occupied_wells()], Destination_Locations):
            print(f"{dna} -> {destination}")

When the DNA_Source_Locations list is shuffled, the variables used in this print statement are not in the same order. This results in a misleading print statement.

Brad0440 commented 2 years ago

See #43 for a solution to this. I might have misunderstood what shuffle is doing, so please check it before merging.