Hi,
We are running Trac 1.6 in a virtualenv on Debian 12, using AccountManager and authenticating towards active directory.
On wiki pages, we usually attach images to pages and use the [[Image()]] -function to have the images shown on the pages.
However, if I try to convert a page to a pdf or printable HTML, the images are not included. Instead there is an empty space in the pdf, and in the printable HTML there is a blurred paperclip(I think).
The page describing TracWikiPrint states that:
"When using cookie based authentication, like AccountManager, the xhtml2pdf library is given a temporary cookie to authenticate the user, so the conversion process will have the same permissions as the user downloading the .pdf, but you must make sure that the project URL is accessible locally from the Trac server itself."
However, we are using wkhtmltopdf and not xhtml2pdf. I don't know if that is the reason it doesn't work.
I have ensured that the images are reachable via the same URL on the trac server itself using lynx.
There is nothing in the trac.log, not even in debug mode. And nothing in the apache log that explains it:
--------------------------------------snip-----------------------------------
10.23.245.53 - - [21/Dec/2023:10:27:35 +0000] "GET /wiki/GeneralGuides HTTP/1.1" 200 5111 "
https://trac01.example.com/wiki" "Mozilla/5.0 (Windows NT 10.0; rv:109.0) Gecko/20100101 Firefox/115.0"
10.23.245.53 - - [21/Dec/2023:10:27:37 +0000] "GET /wiki/GeneralGuides/AguideExampleMarmiteCake HTTP/1.1" 200 4782 "
https://trac01.example.com/wiki/GeneralGuides" "Mozilla/5.0 (Windows NT 10.0; rv:109.0) Gecko/20100101 Firefox/115.0"
10.23.245.53 - - [21/Dec/2023:10:27:37 +0000] "GET /raw-attachment/wiki/GeneralGuides/AguideExampleMarmiteCake/marmitecake.jpg HTTP/1.1" 200 127869 "
https://trac01.example.com/wiki/GeneralGuides/AguideExampleMarmiteCake" "Mozilla/5.0 (Windows NT 10.0; rv:109.0) Gecko/20100101 Firefox/115.0"
10.23.240.22 - - [21/Dec/2023:10:27:41 +0000] "GET /wikiprint/GeneralGuides/AguideExampleMarmiteCake HTTP/1.1" 200 2701 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/534.34 (KHTML, like Gecko) wkhtmltopdf Safari/534.34"
10.23.240.22 - - [21/Dec/2023:10:27:41 +0000] "GET /chrome/common/attachment.png HTTP/1.1" 200 651 "
https://trac01.example.com/wikiprint/GeneralGuides/AguideExampleMarmiteCake" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/534.34 (KHTML, like Gecko) wkhtmltopdf Safari/534.34"
10.23.245.53 - - [21/Dec/2023:10:27:41 +0000] "GET /wiki/GeneralGuides/AguideExampleMarmiteCake?format=pdfpage HTTP/1.1" 200 26444 "
https://trac01.example.com/wiki/GeneralGuides/AguideExampleMarmiteCake" "Mozilla/5.0 (Windows NT 10.0; rv:109.0) Gecko/20100101 Firefox/115.0"
--------------------------------------snip-----------------------------------
Any ideas or suggestions?
Thanks in advance,
/tony
--
Tony Albers - SCSA, SCNA, EMCIE, EMCBA, RHCSA
Banedanmark, Digital Test Center
Carsten Niebuhrs Gade 43, 1577 Copenhagen V