Likely a missing namespace decleration in Jen's source, but she would never know
since the error reporting (from the XSL processor, not PreTeXt) was a bit wonky.
Andrew S has devised a fix, which was just merged, and will roll out in the
usual progression. Nice work on Andrew's part.
https://github.com/PreTeXtBook/pretext/pull/2623
Thanks very much, Jen, for providing a report. You've saved a lot of
head-scratching for a lot of folks down the road.
Rob
On 7/22/25 07:09, Andrew Scholer wrote:
> I *think* this might be related to a missing "xmlns:xi="
http://www.w3.org/2001/
> XInclude <
http://www.w3.org/2001/XInclude>""
>
> I get the mysterious codechat error if the toplevel element on a page is missing
> that namespace declaration. e.g.
> <chapter xml:id="ch-chapter-title">
> instead of
> <chapter xml:id="ch-chapter-title" xmlns:xi="
http://www.w3.org/2001/XInclude
> <
http://www.w3.org/2001/XInclude>">
>
> Jen:
> Do you see an error like this on your xi:include?
> image.png
>
> And can you try this in the terminal:
> *pretext -v DEBUG build*
>
> See if that shows an error like:
> lxml.etree.XMLSyntaxError: Namespace prefix xi on include is not defined...
>
> On Mon, Jul 21, 2025 at 8:37 PM 'Rob Beezer' via PreTeXt support <pretext-
>
sup...@googlegroups.com <mailto:
pretext...@googlegroups.com>> wrote:
>
> Dear Jen,
>
> I was waiting to hear from Oscar.
>
> Shot in the dark - try putting an @xml:id on the #interactive and the
> #slate, just to see what happens.
>
> Rob
>
> On July 21, 2025 8:31:03 PM PDT, Oscar Levin <
oscar...@gmail.com
> <mailto:
oscar...@gmail.com>> wrote:
> >Other than this warning, does your document build and display things
> >correctly? Codechat is a way to preview files side by side, and isn't
> >strictly necessary for pretext.
> >
> >On Mon, Jul 21, 2025, 7:20 PM '
jfir...@linfield.edu
> <mailto:
jfir...@linfield.edu>' via PreTeXt support <
> >
pretext...@googlegroups.com <mailto:
pretext-
>
sup...@googlegroups.com>> wrote:
> >
> >> I am trying to include a Doenet activity in a textbook. I have the
> >> activity as a separate file and am using xi:include as follows:
> >>
> >> <interactive label="doenetminimaxgraph" platform="doenetml" width="100%"
> >> aspect="40:43">
> >> <slate surface="doenetml">
> >>
> >> <xi:include parse="text" href="doenet/minimaxgraph.xml"/>
> >>
> >> </slate>
> >> </interactive>
> >>
> >> It seems that the xi:include is the main issue as I am getting a warning:
> >> warning: Failed to map codechat path to xml id; codechat will not work.
> >>
> >> When I comment out the interactive (or just the xi:include statement ) I
> >> do not get this warning. I tried a minimal amount of text in the
> >> minimaxgraph.xml file and I still get this error.
> >>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "PreTeXt support" group.
> >> To unsubscribe from this group and stop receiving emails from it, send an
> >> email to
pretext-suppo...@googlegroups.com <mailto:
pretext-
>
support%2Bunsu...@googlegroups.com>.
> >> <
https://groups.google.com/d/msgid/pretext-
> support/6dc40157-66b5-46d8-884a-962df8a2741bn%
40googlegroups.com?
> utm_medium=email&utm_source=footer <
https://groups.google.com/d/msgid/
> pretext-support/6dc40157-66b5-46d8-884a-962df8a2741bn%
40googlegroups.com?
> utm_medium=email&utm_source=footer>>
> >> .
> >>
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "PreTeXt support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to
pretext-suppo...@googlegroups.com <mailto:
pretext-
>
support%2Bunsu...@googlegroups.com>.
> support/MTAwMDAwNC5iZWV6ZXI.1753155432%40pnsh <
https://groups.google.com/d/
> msgid/pretext-support/MTAwMDAwNC5iZWV6ZXI.1753155432%40pnsh>.
>
> --
> You received this message because you are subscribed to the Google Groups
> "PreTeXt support" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to
pretext-suppo...@googlegroups.com <mailto:
pretext-
>
support+u...@googlegroups.com>.
> CACm44N_K31MkgUsGYdwPRkyR5n51gWi7V%2BVuMt-Q_3RFJyTXOQ%
40mail.gmail.com <https://
>
groups.google.com/d/msgid/pretext-support/
> CACm44N_K31MkgUsGYdwPRkyR5n51gWi7V%2BVuMt-Q_3RFJyTXOQ%
40mail.gmail.com?
> utm_medium=email&utm_source=footer>.