Saxon-EE profiling HTML not well-formed
Running Saxon-EE with "-TP" option for profiling produces a not well-formed HTML document. The element /html/head/meta is not terminated with a closing tag.
I am running Saxon-EE 188.8.131.52 in Oxygen XML Editor 23.1
Updated by Michael Kay 30 days ago
In HTML (as distinct from XHTML), no closing tag is required for meta elements. See https://stackoverflow.com/questions/19506028/do-you-need-to-close-meta-and-link-tags-in-html
Unfortunately the TimingTraceListener isn't really designed to be customised, except by taking a copy of the source code and adapting it to produce your own version. I'll look at making some methods overridable, or providing some other way to capture the results into a user-supplied stylesheet.
Updated by Oliver Budke 29 days ago
Thank you for your explanation.
Is there any other way to obtain a trace listener output that is readable by an XSL transformation, i.e. producing a well-formed XML document? I need a list of all templates that have been called and use this information for another transformation.
]init[ AG für digitale Kommunikation
Updated by Michael Kay 29 days ago
I would suggest writing your own
TraceListener to capture this information; you could do this by modifying the source code of
TimingTraceListener, which can be found at
Alternatively, you can read HTML in a transformation by using the
saxon:parse-html() extension function, or by setting up a SAXSource that uses TagSoup or validator.nu as the XMLReader. But this is a "screen-scraping" approach in which you become dependent on the detailed format of the HTML output, which is not stable or documented.
Updated by Oliver Budke 17 days ago
I tried a couple of things with the TimingTraceListener. However, I cannot find the stylesheet profile.xsl which is called on line 242. Could you provide me the file that I can make my necessary changes there? It seems easiest for my production environment to just output an xhtml file.
Updated by Michael Kay 17 days ago
You can find it at
Incidentally, next to it there is a
profile-json.xsl, which I suspect was an attempt to allow the timing data to be output in JSON, but I don't know if this was ever tested.
Please register to edit this issue