kakwa / ldapcherry

Web UI for managing users and groups in multiple directory services.
MIT License
225 stars 70 forks source link

Can't locate template for uri 'index.tmpl' #71

Closed nenee-ai closed 8 months ago

nenee-ai commented 8 months ago

[18/Jan/2024:15:51:07] loading templates from dir '/usr/share/ldapcherry/templates/' [18/Jan/2024:15:51:07] uncaught exception: [Can't locate template for uri 'index.tmpl'] [18/Jan/2024:15:51:07]
Traceback (most recent call last): File "/Users/nenne-ai/Library/Python/3.12/lib/python/site-packages/mako/lookup.py", line 240, in get_template return self._check(uri, self._collection[uri])


KeyError: 'index.tmpl'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/ldapcherry-1.1.1-py3.12.egg/ldapcherry/__init__.py", line 418, in reload
    self._load_templates(config)
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/ldapcherry-1.1.1-py3.12.egg/ldapcherry/__init__.py", line 394, in _load_templates
    self.temp[t] = self.temp_lookup.get_template(t)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/nenne-ai/Library/Python/3.12/lib/python/site-packages/mako/lookup.py", line 253, in get_template
    raise exceptions.TopLevelLookupException(
mako.exceptions.TopLevelLookupException: Can't locate template for uri 'index.tmpl'
[18/Jan/2024:15:51:07]  application failed to start
nenee-ai commented 8 months ago

We can set these in the ldapcherry.ini file.

templates.dir = '/usr/share/ldapcherry/templates/' tools.staticdir.dir = '/usr/share/ldapcherry/static/'