Validating XML in Windows

O

Omari Norman

My app needs to validate XML. That's easy enough in Unix. What is the
best way to do it in Windows?

The most obvious choice would of course be PyXML. However, apparently it
is no longer maintained:

http://sourceforge.net/project/showfiles.php?group_id=6473

so there are no Windows binaries that work with Python 2.5. Getting
other XML libraries like libxml2 also seems to be quite difficult on
Windows.

Has anyone else dealt with this problem and found a solution? It would
even be fine if I could find a free command-line validator that I could
invoke with subprocess, but I haven't even had luck with that.

Thanks,
Omari
 
S

Stefan Behnel

Omari said:
My app needs to validate XML. That's easy enough in Unix. What is the
best way to do it in Windows?

The most obvious choice would of course be PyXML. However, apparently it
is no longer maintained:

http://sourceforge.net/project/showfiles.php?group_id=6473

so there are no Windows binaries that work with Python 2.5. Getting
other XML libraries like libxml2 also seems to be quite difficult on
Windows.

Has anyone else dealt with this problem and found a solution? It would
even be fine if I could find a free command-line validator that I could
invoke with subprocess, but I haven't even had luck with that.

lxml has statically built Windows binaries available for version 1.2.1, those
for 1.3.2 should become available soon. It supports RelaxNG, XMLSchema, DTDs
and (with a little patching) Schematron.

http://codespeak.net/lxml/

Stefan
 
B

bsneddon

lxml has statically built Windows binaries available for version 1.2.1, those
for 1.3.2 should become available soon. It supports RelaxNG, XMLSchema, DTDs
and (with a little patching) Schematron.

http://codespeak.net/lxml/

Stefan

You might try something like this. I am sure you can find help on
MSDN.
I know DOM may not be most efficient but could be a way to solve the
problem
on windows.True
# not sure how to load schema but there must be away
 
N

numeralblue

My app needs to validate XML. That's easy enough in Unix. What is the
best way to do it in Windows?

The most obvious choice would of course be PyXML. However, apparently it
is no longer maintained:

http://sourceforge.net/project/showfiles.php?group_id=6473

I use the xmlproc parser that is included in PyXML. It is pure Python
so
as a temporary solution it is easy to include it with my source. I
haven't
had problems with it yet even though it is dated as you mentioned.

--Miguel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,241
Members
46,831
Latest member
RusselWill

Latest Threads

Top