forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Dixon <...@dixons.org>
Subject Re: xinclude
Date Wed, 06 Sep 2006 14:53:52 GMT
On Wed, 6 Sep 2006, Thorsten Scherler wrote:

> > > > My only use of XInlude appears above.  In logMeIn.xml I
> > > >
> > > > (a) add an xmlns:xi attribute to the document element
> > > > (b) add the xi:xinclude element
> > > >
> > > > Is either incorrect?  Is there something else I should be doing?
> > >
> > > No that is fine. You also define the xinclude transformer in your
> > > sitemap, this is not necessary as it is defined in the root Forrest
> > > sitemap, but it will not be causing a problem.
> >
> > [Some readers will recall that there is no project sitemap.]
> >
> > Well, it doesn't cause a problem if you do a 'forrest run', but if
> > you do a 'forrest site', it fails:
> > ------------------------------------------------------------------------
> > validate-xdocs:
> > /home/j2ee/jappgen/src/documentation/content/xdocs/eg/logMeIn.xml:4:54:
> > Attribute "xmlns:xi" must be declared for element type "document".
> > /home/j2ee/jappgen/src/documentation/content/xdocs/eg/logMeIn.xml:13:73:
> > Element type "xi:include" must be declared.
> > /home/j2ee/jappgen/src/documentation/content/xdocs/eg/logMeIn.xml:13:82:
> > The content of element type "source" must match
> > "(strong|em|code|sub|sup|br|img|icon|acronym|map|a)".
> > ------------------------------------------------------------------------
> >
> > Now I'm hoping that there is a simple workaround that I am missing but ...
>
> Well it looks like the xinclude transformation got not executed before
> the validation. The quickest way would be to exclude the url for
> validation in the forrest.properties.

Yes. If I set
  forrest.validate.xdocs=false
in forrest.properties, then the 'forrest site' works.

That is, this is indeed a simple workaround, for which I thank you.

However, bear in mind that 'forrest run' did not fail.  Also, 'forrest
validate-xdocs' returns
  BUILD SUCCESSFUL
implying that there is an inconsistency in the way in which validation
is applied.  For exactly the same configuration

  forrest run            succeeds
  forrest validate-xdocs succeeds
  forrest site           fails

Looks like a bug to me.

--
Jim Dixon  jdd@dixons.org   tel +44 117 982 0786  mobile +44 797 373 7881

Mime
View raw message