You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xalan.apache.org by "Mikhail T." <mi...@aldan.algebra.com> on 2023/02/08 19:48:00 UTC

xalan-2.7.2 quietly ignores failure to download a DTD

Hello!

For about twenty years I've maintained my resume in XML format 
<https://xmlresume.sourceforge.net/>, relying on Xalan (and fop) to 
produce TXT, HTML, and PDF renderings from the same source.

The command-line used for, for example, the plain TXT version was -- and 
remains:

    java -cp .../xalan.jar org.apache.xalan.xslt.Process -in resume.xml
    -xsl .../resume-1_5_1/xsl/output/us-text.xsl > resume.txt

Having tried the above command today, I noticed that the output files -- 
all flavors -- are /empty/. Java produces no errors, exits with code 0, 
but yields blank output...

Only after installing Xalan-C -- and processing the same XML input with 
that, did I get the proper diagnostics:

    Xalan example1.xml .../xsl/output/us-text.xsl
    Fatal Error: unable to open file
    'https://xmlresume.sourceforge.net/dtd/resume.dtd'

I was then able to replace the remote reference to resume.dtd with a 
local one, and things began to work properly. Why wouldn't Xalan-J yield 
the same (or similar) error-message in reaction to the same error? Why 
would it exit with 0 exit code?

Thank you! Yours,

    -mi

Re: xalan-2.7.2 quietly ignores failure to download a DTD

Posted by "Mikhail T." <mi...@aldan.algebra.com>.
09.02.23 08:06, Gary Gregory пише:
> Java version? Xalan version?


% java -showversion -jar /opt/share/java/classes/xalan.jar -v
openjdk version "1.8.0_332"
OpenJDK Runtime Environment (build 1.8.0_332-b09)
OpenJDK 64-Bit Server VM (build 25.332-b09, mixed mode)

 >>>>>>> Xalan Version Xalan Java 2.7.2, <<<<<<<


Re: xalan-2.7.2 quietly ignores failure to download a DTD

Posted by Gary Gregory <ga...@gmail.com>.
Java version? Xalan version?

Gary

On Wed, Feb 8, 2023, 17:49 Mikhail T. <mi...@aldan.algebra.com> wrote:

> Hello!
>
> For about twenty years I've maintained my resume in XML format
> <https://xmlresume.sourceforge.net/>, relying on Xalan (and fop) to
> produce TXT, HTML, and PDF renderings from the same source.
>
> The command-line used for, for example, the plain TXT version was -- and
> remains:
>
> java -cp .../xalan.jar org.apache.xalan.xslt.Process -in resume.xml -xsl
> .../resume-1_5_1/xsl/output/us-text.xsl > resume.txt
>
> Having tried the above command today, I noticed that the output files --
> all flavors -- are *empty*. Java produces no errors, exits with code 0,
> but yields blank output...
>
> Only after installing Xalan-C -- and processing the same XML input with
> that, did I get the proper diagnostics:
>
> Xalan example1.xml  .../xsl/output/us-text.xsl
> Fatal Error: unable to open file '
> https://xmlresume.sourceforge.net/dtd/resume.dtd'
>
> I was then able to replace the remote reference to resume.dtd with a local
> one, and things began to work properly. Why wouldn't Xalan-J yield the same
> (or similar) error-message in reaction to the same error? Why would it exit
> with 0 exit code?
>
> Thank you! Yours,
>
> -mi
>
>