Hi,

On 2022/10/17 19:42, Roger Oberholtzer wrote:
> Unable to view a wiki page in Trac 1.5.4
> 
> I have a wiki page that contains only Wiki formatting. No macros or
> anything. All just text. The page might be large. But other than that
> I cannot think of why there should be an error showing it.
> 
> When I try to view the page, I see this in the trac log:
> 
> Traceback (most recent call last):
>  File 
> "/usr/lib/python3.10/site-packages/Trac-1.5.4.dev0-py3.10.egg/trac/web/main.py",
> line 610, in dispatch_request
>    dispatcher.dispatch(req)
>  File 
> "/usr/lib/python3.10/site-packages/Trac-1.5.4.dev0-py3.10.egg/trac/web/main.py",
> line 302, in dispatch
>    raise e
>  File 
> "/usr/lib/python3.10/site-packages/Trac-1.5.4.dev0-py3.10.egg/trac/web/main.py",
> line 248, in dispatch
>    resp = chosen_handler.process_request(req)
>  File 
> "/usr/lib/python3.10/site-packages/Trac-1.5.4.dev0-py3.10.egg/trac/web/chrome.py",
> line 718, in process_request
>    in provider.get_htdocs_dirs() or []
>  File 
> "/usr/lib/python3.10/site-packages/TracWikiPrint-4.0.0.dev0-py3.10.egg/tracpdf/admin.py",
> line 153, in get_htdocs_dirs
>    return [('wikiprint', resource_filename(__name__, 'htdocs'))]
>  File "/usr/lib/python3.10/site-packages/pkg_resources/__init__.py",
> line 1154, in resource_filename
>    return get_provider(package_or_requirement).get_resource_filename(
>  File "/usr/lib/python3.10/site-packages/pkg_resources/__init__.py",
> line 1763, in get_resource_filename
>    return self._extract_resource(manager, zip_path)
>  File "/usr/lib/python3.10/site-packages/pkg_resources/__init__.py",
> line 1785, in _extract_resource
>    timestamp, size = self._get_date_and_size(self.zipinfo[zip_path])
> KeyError: 'tracpdf/htdocs'
> 2022-10-17 12:30:45,256 Trac[main] ERROR: [10.2.10.41] Internal Server
> Error: <RequestWithSession "GET '/chrome/tracwysiwyg/wysiwyg.js'">,
> referrer 
> 'http://sto-opq-src.scc.se/systems/wiki/StandardLinux/leap15.3/packages'
> 
> I see the bits about tracpdf. I am not selecting that here. I never
> get to the page so I can do so. All other wiki pages seem fine. Just
> the three similar ones to this.

That's a TracWikiPrintPlugin issue. It is caused by htdocs/css/*.css files not 
installed.

$ pip show -f TracWikiPrint
...
Files:
  TracWikiPrint-4.0.0.dev0.dist-info/COPYING
  TracWikiPrint-4.0.0.dev0.dist-info/INSTALLER
  TracWikiPrint-4.0.0.dev0.dist-info/METADATA
  TracWikiPrint-4.0.0.dev0.dist-info/RECORD
  TracWikiPrint-4.0.0.dev0.dist-info/REQUESTED
  TracWikiPrint-4.0.0.dev0.dist-info/WHEEL
  TracWikiPrint-4.0.0.dev0.dist-info/direct_url.json
  TracWikiPrint-4.0.0.dev0.dist-info/entry_points.txt
  TracWikiPrint-4.0.0.dev0.dist-info/top_level.txt
  tracpdf/__init__.py
  tracpdf/__init__.pyc
  tracpdf/admin.py
  tracpdf/admin.pyc
  tracpdf/pdfbook.py
  tracpdf/pdfbook.pyc
  tracpdf/templates/wikiprint_admin_parameters.html
  tracpdf/templates/wikiprint_parameters.html
  tracpdf/util.py
  tracpdf/util.pyc
  tracpdf/wikiprint.py
  tracpdf/wikiprint.pyc

Please create a new ticket using 
https://trac-hacks.org/newticket?component=TracWikiPrintPlugin

Index: setup.py
===================================================================
--- setup.py    (revision 18497)
+++ setup.py    (working copy)
@@ -33,8 +33,7 @@
     version='4.0.0',
     packages=['tracpdf'],
     package_data={
-        'tracpdf': ['templates/*.html'
-        ]
+        'tracpdf': ['templates/*.html', 'htdocs/css/*.css'],
     },
     install_requires=['pdfkit', 'trac'],
     author='Cinc-th',


-- 
Jun Omae <jun6...@gmail.com> (大前 潤)

-- 
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to trac-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/trac-users/99bad53b-757b-2605-69d2-1ac000b57bae%40gmail.com.

Reply via email to