Dear list, when dealing with XML, sometimes I find errors that I don’t know where they might come from. Is it possible to get the full ConTeXt source from a XML document instead of typesetting it? Many thanks for your help, Pablo -- http://www.ousia.tk
Hi, On a similar vein: I get my XML files from an outside source, and I sometimes forget to call xmllint before processing. Is there a chance for ConTeXt to report a warning when it encounters issues with the XML? Best wishes, Taco
On 22 Oct 2018, at 21:23, Pablo Rodriguez
wrote: Dear list,
when dealing with XML, sometimes I find errors that I don’t know where they might come from.
Is it possible to get the full ConTeXt source from a XML document instead of typesetting it?
Many thanks for your help,
Pablo -- http://www.ousia.tk ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
Taco Hoekwater Elvenkind BV
On Tue, Oct 23, 2018 at 9:04 AM Taco Hoekwater
Hi,
On a similar vein: I get my XML files from an outside source, and I sometimes forget to call xmllint before processing. Is there a chance for ConTeXt to report a warning when it encounters issues with the XML?
hm xmllint is also a validating parser... I don't think there is much to gain in re-implementing all in lua ... even a lua binding is questionable . -- luigi
On 23 Oct 2018, at 09:16, luigi scarso
wrote: On Tue, Oct 23, 2018 at 9:04 AM Taco Hoekwater
wrote: Hi, On a similar vein: I get my XML files from an outside source, and I sometimes forget to call xmllint before processing. Is there a chance for ConTeXt to report a warning when it encounters issues with the XML?
hm xmllint is also a validating parser... I don't think there is much to gain in re-implementing all in lua ... even a lua binding is questionable .
Sure, but as it stands ConTeXt silently ignores (== do not process at all) broken XML files. Some sort of indication that not all is right would be really helpful, even if it was just “xml file contained no elements”. Taco
On 10/23/2018 9:03 AM, Taco Hoekwater wrote:
Hi,
On a similar vein: I get my XML files from an outside source, and I sometimes forget to call xmllint before processing. Is there a chance for ConTeXt to report a warning when it encounters issues with the XML? examples ... i thought that there is a kind of error message on the console (at least in a tex run)
Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
On 23. Oct 2018, at 10:43, Hans Hagen
wrote: examples ... i thought that there is a kind of error message on the console (at least in a tex run)
Yes, I often get errors like “can’t close tag <foo> with </bar> on line XXXX.” But I don’t know in which situations these messages pop up and when context simply bails out. Thomas
Hm, I usually get a variation of “invalid xml file” typeset inside the document, but nothing on the command line. See attached example. Best wishes, Taco
On 23 Oct 2018, at 11:04, Thomas A. Schmitz
wrote: On 23. Oct 2018, at 10:43, Hans Hagen
wrote: examples ... i thought that there is a kind of error message on the console (at least in a tex run)
Yes, I often get errors like “can’t close tag <foo> with </bar> on line XXXX.” But I don’t know in which situations these messages pop up and when context simply bails out.
Thomas ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
Taco Hoekwater Elvenkind BV
On 10/23/2018 11:04 AM, Thomas A. Schmitz wrote:
On 23. Oct 2018, at 10:43, Hans Hagen
wrote: examples ... i thought that there is a kind of error message on the console (at least in a tex run)
Yes, I often get errors like “can’t close tag <foo> with </bar> on line XXXX.” But I don’t know in which situations these messages pop up and when context simply bails out.
normally when i see such an error i check the file with tidy Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
participants (5)
-
Hans Hagen
-
luigi scarso
-
Pablo Rodriguez
-
Taco Hoekwater
-
Thomas A. Schmitz