You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Qualify each NXDL file by validating it against the NXDL Schema (nxdl.xsd) before it is used. This will ensure the NXDL is proper (and has no errors introduced).
Here is some python code that does this:
def validate_xml(xml_file_name):
'''
validate an NXDL XML file against an XML Schema file
:param str xml_file_name: name of XML file
'''
xml_tree = lxml.etree.parse(xml_file_name)
xsd = cache.get_XML_Schema()
return xsd.assertValid(xml_tree)
Use the libxml2 library to perform this validation step.
The text was updated successfully, but these errors were encountered:
Qualify each NXDL file by validating it against the NXDL Schema (
nxdl.xsd
) before it is used. This will ensure the NXDL is proper (and has no errors introduced).Here is some python code that does this:
Use the libxml2 library to perform this validation step.
The text was updated successfully, but these errors were encountered: