Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
VIGNET Pierre
cadbiom
Commits
e9629913
Commit
e9629913
authored
Jan 18, 2020
by
VIGNET Pierre
Browse files
[lib] proper error handling during the model parsing
parent
56fdb768
Changes
1
Show whitespace changes
Inline
Side-by-side
library/cadbiom/models/guard_transitions/translators/chart_xml.py
View file @
e9629913
...
...
@@ -371,10 +371,10 @@ class MakeHandler(ContentHandler):
try
:
node_ori
=
self
.
node_dict
[
ori
]
node_ext
=
self
.
node_dict
[
ext
]
except
Exception
as
exc
:
print
(
"Bad xml file - missing nodes
"
,
ori
,
" -> "
,
ext
)
print
(
self
.
node_dict
)
print
(
exc
)
except
KeyError
as
exc
:
LOGGER
.
error
(
"Bad xml file - missing nodes
%s in %s -> %s"
,
exc
,
ori
,
ext
)
LOGGER
.
error
(
"Nodes in memory: %s"
,
self
.
node_dict
)
raise
self
.
current_element
=
self
.
top_pile
.
add_transition
(
node_ori
,
node_ext
)
# The transition may not be created (origin = ext for example)
...
...
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