Project

Profile

Help

Bug #5941

closed

SaxonC EE 12.1 Validate command line tool seems broken; doesn't give any output

Added by Martin Honnen about 1 year ago. Updated 12 months ago.

Status:
Closed
Priority:
Normal
Category:
Samples
Start date:
2023-03-26
Due date:
% Done:

100%

Estimated time:
Found in version:
12.1
Fixed in version:
12.2
Platforms:

Description

I don't get any output from the SaxonC EE 12.1 command line tool for schema based validation, both on Windows with e.g. PS C:\Program Files\Saxonica\libsaxon-EEC-windows-v12.1\command> .\Validate.exe -t -s:..\samples\data\books-invalid.xml -xsd:..\samples\data\books.xsd and on Linux with e.g. mh@DESKTOP-TMRJML3:~/libsaxon-EEC-linux-v12.1/command$ ./validate -t -s:../samples/data/books-invalid.xml -xs d:../samples/data/books.xsd I don't get any output.

Meanwhile SaxonCS 12.1 clearly gives validation errors e.g.

PS C:\Program Files\Saxonica\libsaxon-EEC-windows-v12.1\command> & 'C:\Program Files\Saxonica\SaxonCS-12.0\SaxonCS.exe' validate -t -s:..\samples\data\books-invalid.xml -xsd:..\samples\data\books.xsd
SaxonCS-EE 12.0 from Saxonica
.NET 6.0.10 on Windows 10.0.22621.0
Using license serial number ...
Loading schema document file:///C:/Program Files/Saxonica/libsaxon-EEC-windows-v12.1/samples/data/books.xsd
Finished loading schema document file:///C:/Program Files/Saxonica/libsaxon-EEC-windows-v12.1/samples/data/books.xsd
Schema checking successful. Time: 110ms.
Memory used: 1Mb
Processing file:///C:/Program Files/Saxonica/libsaxon-EEC-windows-v12.1/samples/data/books-invalid.xml
Validation error on line 3 column 5 of books-invalid.xml:
  FORG0001: Attribute @x is not allowed on element <BOOKS>
  See https://www.w3.org/TR/xmlschema11-1/#cvc-complex-type clause 3
Validation error on line 10 column 23 of books-invalid.xml:
  FORG0001: The content "$0.2" of element <PRICE> does not match the required simple type.
  Cannot convert string to decimal: $0.2
  See https://www.w3.org/TR/xmlschema11-2/#cvc-datatype-valid clause 1
Validation error on line 21 column 32 of books-invalid.xml:
  FORG0001: The content "2002-02-31" of element <PUB-DATE> does not match the required
  simple type. Invalid date "2002-02-31" (Non-existent date)
  See https://www.w3.org/TR/xmlschema11-2/#cvc-datatype-valid clause 1
Validation error on line 42 column 11 of books-invalid.xml:
  FORG0001: In content of element <ITEM>: The content model does not allow element
  <REPUTATION> to appear immediately after element <WEIGHT>. No further elements are allowed
  at this point.
  See https://www.w3.org/TR/xmlschema11-1/#cvc-complex-type clause 2.4
Failed to process file ..\samples\data\books-invalid.xml: Four validation errors were reported. First error: Attribute @x is not allowed on element <BOOKS>
Exiting with code 2

I would expect a similar output from the SaxonC EE 12.1 Validate command line tool.

Note I file this on category "Samples" as a category "command line tools" seems to be missing.

Please register to edit this issue

Also available in: Atom PDF