Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tbgl
tools
mrdna
Commits
42f941f9
Commit
42f941f9
authored
Aug 13, 2019
by
cmaffeo2
Browse files
Slightly improved error when circular DNA is encountered
parent
6c55001d
Changes
1
Hide whitespace changes
Inline
Side-by-side
mrdna/segmentmodel.py
View file @
42f941f9
...
...
@@ -781,7 +781,8 @@ class Segment(ConnectableElement, Group):
for
s
in
self
.
strand_pieces
[
d
]:
l
,
h
=
sorted
((
s
.
start
,
s
.
end
))
for
value
in
(
strand_piece
.
start
,
strand_piece
.
end
):
assert
(
value
<
l
or
value
>
h
)
if
value
>=
l
and
value
<=
h
:
raise
Exception
(
"Strand piece already exists! DNA may be circular."
)
## Add strand_piece in correct order
self
.
strand_pieces
[
d
].
append
(
strand_piece
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment