[xml] xmllint: no line numbers in --dtdvalid validation output (bugzilla #131545)



I just filed an enhancement request (Gnome bugzilla #131545) for this issue

  http://bugzilla.gnome.org/show_bug.cgi?id=131545

But I wanted to ask about it on the list in case I'm misunderstanding
the purpose of --dtdvalid.

The issue is that --dtdvalid output is missing some data that --valid
output provides. For one thing, the output doesn't include the line
numbers that --valid output includes. So, --dtdvalid output isn't very
useful in helping you find the location of the errors in a doc instance
do that you can fix them. For example, --dtdvalid only gives me error
message like this:

  Element formalpara content does not follow the DTD, expecting (title, indexterm* , para), got (title 
procedure)

But --valid gives me this:

  doc.xml:190: element formalpara: validity error : Element formalpara content does not follow the DTD, 
expecting (title , indexterm* , para), got (title itemizedlist)
  <literal>-unlockServer</literal>.</para></listitem></itemizedlist></formalpara>
                                                                                ^

Is it reasonable to expect that xmllint might be enhanced to have
--dtdvalid output match --valid output? Is there some limitation that
prevents this? Or is it intentional that output for --dtdvalid should
lack this info?

  --Mike

P.S. The reason I don't just use --valid is that it requires a DOCTYPE
declaration to be in the file I'm trying to validate, and I don't
actually want to have one in the file.

Attachment: pgpzR_2BMhXF5.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]