[Trac] mod_python and colored diffs
Matthew Gillen
mgillen at bbn.com
Fri Jun 10 11:23:06 CDT 2005
Emmanuel-G BLOT wrote:
> Matthew Gillen wrote:
>
>> Hi,
>> I'm using Apache+mod_python to run Trac, and the diffs are not colored.
>> If I use 'tracd' to run Trac, I get colored diffs no problem. So I'm
>> thinking there must be something screwy in my apache config (ie it can't
>> run enscript or something).
>
>
> Might be a CSS issue. Did you check that the diff.css was available to
> your web client ?
> * Go to the erroneous diff page
> * Look at the HTML source. In the header, you'll find something like
> <link rel="stylesheet" href="/trac/css/diff.css" type="text/css" />
> * Create a new URL and ask the web client to load it:
> http://server/<href> in the above line, e.g. from the above example
> http://server/trac/css/diff.css
>
> If the web client cannot load this page, you probably have a trouble
> with your Apache configuration file.
>
I think you're on to something:
The erroneous diff page has this code in the header:
<style type="text/css">
@import url(/trac/css/trac.css);
@import url(/trac/css/changeset.css);
Now bringing up 'http://hostname/trac/css/trac.css' shows the contents
of the css file, as expected. However, replacing changeset.css for
trac.css brings me to the top-level start page (ie project listing; just
like any malformed URL that trac can't figure out). Interestingly, the
diff.css seems ok (ie just like trac.css).
There's nothing in Apache's errorlog about file not found or anything.
So, I think you're right, but I'm not real sure where to go from here...
Thanks,
Matt
More information about the Trac
mailing list