Skip to content

Commit

Permalink
Try reverting XMLValidator workaround for NREL/OpenStudio#4824.
Browse files Browse the repository at this point in the history
  • Loading branch information
shorowit committed Jan 16, 2024
1 parent 9d6504d commit 7292979
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions HPXMLtoOpenStudio/resources/xmlvalidator.rb
Expand Up @@ -21,13 +21,7 @@ def self.validate_against_schema(hpxml_path, validator, errors = [], warnings =
end

def self.get_schematron_validator(schematron_path)
# First create XSLT at our specified output path to avoid possible errors due
# to https://github.com/NREL/OpenStudio/issues/4824.
xslt_dir = Dir.mktmpdir('xmlvalidation-')
OpenStudio::XMLValidator::schematronToXslt(schematron_path, xslt_dir)
xslt_path = File.join(xslt_dir, File.basename(schematron_path, '.xml') + '_stylesheet.xslt')

return OpenStudio::XMLValidator.new(xslt_path)
return OpenStudio::XMLValidator.new(schematron_path)
end

def self.validate_against_schematron(hpxml_path, validator, hpxml_doc, errors = [], warnings = [])
Expand Down

0 comments on commit 7292979

Please sign in to comment.