#5431 closed defect (worksforme)
Misplaced XML declaration causes Firefox to report error w/ Agilo plugin
Reported by: | Robin Macharg | Owned by: | Emmanuel Blot |
---|---|---|---|
Priority: | normal | Component: | RevtreePlugin |
Severity: | normal | Keywords: | firefox, xml, svn, agilo |
Cc: | Trac Release: | 0.11 |
Description
When attempting to view the main RevTree page Firefox reports an XML Parsing Error:
XML Parsing Error: XML or text declaration not at start of entity Location: http://127.0.0.1/trac/revtree Line Number 4, Column 3: <?xml version="1.0" encoding="UTF-8"?> --^
Looking at the source I see:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <?xml version="1.0" encoding="UTF-8"?> <head> <title> Revision Tree – WSGI Test </title> ... <SNIP>
(Spacing/CRLFs left in intentionally) It's obvious that the <?XML> declaration is out of place. I'm using the following:
- Vista Pro 32
- Apache as follows: Apache/2.2.11 (Win32) mod_wsgi/2.5 Python/2.6.2 mod_jk/1.2.28
- Trac 0.11.4, including the following plugins:
- Agilo 0.7.4.1
- NavAdd 0.1
- HudsonTrac 0.2
- iniAdmin 0.2
- Firefox 3.0.11
The various other plugins seem to work OK, and the Tomcat integration I have doesn't appear to interfere with Trac in any way.
I've tried taking a copy of the HTML and editing it by hand but I'm guessing that the external Javascript dependencies are frustrating my attempts to get something generated. AFAIK there's no issue with the Trac/SVN link; I'm able to browse the repository fine.
Attachments (0)
Change History (4)
comment:1 Changed 16 years ago by
Keywords: | agilo added |
---|---|
Severity: | major → normal |
comment:2 Changed 16 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Have a look at revtreeplugin/0.11/revtree/templates/revtree.html
There is no such <?xml ...>
declaration here, and as you said, without the agilo plugin, no <?xml>
tag appears.
I'd suggest you contact the Agilo plugin maintainers and see if their template filtering works as expected with XML templates such as the one the RevtreePlugin is using (XHTML + SVG + MATHML). Maybe they should not attempt to filter documents that are not pure XHTML...
Feel free to repopen this ticket if the issue comes from Trac. AFAICT, the RevtreePlugin output complies with XML syntax and the aforementioned grammars.
comment:3 Changed 16 years ago by
Summary: | Misplaced XML declaration causes Firefox to report error → Misplaced XML declaration causes Firefox to report error w/ Agilo plugin |
---|
comment:4 Changed 15 years ago by
For completeness: removing the XML declaration (i.e. <?XML ...?>
)from the main Agilo theme template seems to allow the two plugins to coexist happily. In my case it's located here:
C:\Python26\Lib\site-packages\agilo-0.7.4.1_r1624_20090611-py2.4.egg\agilo\templates\theme.html
.
This may vary depending on how you've installed Agilo, and it might for instance be under the Trac plugins directory.
Digging a little deeper, this appears to be an issue caused by the Agilo plugin (http://www.agile42.com/cms/pages/agilo/) fiddling with the look and feel of a standard Trac installation. Revtree works until Agilo is activated, at which point it starts to fail. Deactivating Agilo doesn't seem to have the reverse effect.
I don't currently know enough about Trac's templating to hazard a guess where any blame should lie, and whether there's an easy fix on either side.