Skip to content

Commit 7d48e95

Browse files
committed
Update scadnano.py
1 parent 71278d7 commit 7d48e95

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

scadnano/scadnano.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6611,19 +6611,19 @@ def _cadnano_v2_place_crossover(helix_from_dct: Dict[str, Any], helix_to_dct: Di
66116611
helix_from_dct[strand_type][end_from - 1][2:] = [helix_to, start_to]
66126612
helix_to_dct[strand_type][end_to - 1][:2] = [helix_from, start_from]
66136613
if helix_from_dct["row"] % 2 != helix_to_dct["row"] % 2:
6614-
raise ValueError("Paranemic crossovers are only allowed between helices that have the same parity of "
6615-
f"row number, here helix num {helix_from_dct['num']} and helix num "
6616-
f"{helix_to_dct['num']} have different parity of row number: respectively "
6617-
f"{helix_from_dct['row']} and {helix_to_dct["row"]}")
6614+
raise ValueError(f"""\
6615+
Paranemic crossovers are only allowed between helices that have the same parity of
6616+
indices (both even or both odd), but here helix indices {helix_from_dct['num']} and {helix_to_dct['num']}
6617+
have different parity: respectively {helix_from_dct['row']} and {helix_to_dct['row']}""")
66186618

66196619
elif not forward_from and not forward_to:
66206620
helix_from_dct[strand_type][start_from][2:] = [helix_to, end_to - 1]
66216621
helix_to_dct[strand_type][end_to - 1][:2] = [helix_from, start_from]
66226622
if helix_from_dct["row"] % 2 != helix_to_dct["row"] % 2:
6623-
raise ValueError("Paranemic crossovers are only allowed between helices that have the same parity of "
6624-
f"row number, here helix num {helix_from_dct['num']} and helix num "
6625-
f"{helix_to_dct['num']} have different parity of row number: respectively "
6626-
f"{helix_from_dct['row']} and {helix_to_dct['row']}")
6623+
raise ValueError(f"""\
6624+
Paranemic crossovers are only allowed between helices that have the same parity of
6625+
indices (both even or both odd), but here helix indices {helix_from_dct['num']} and {helix_to_dct['num']}
6626+
have different parity: respectively {helix_from_dct['row']} and {helix_to_dct['row']}""")
66276627

66286628
@staticmethod
66296629
def _cadnano_v2_color_of_stap(color: Color, domain: Domain) -> List[int]:

0 commit comments

Comments
 (0)