lektor / lektor-tags

For each tag on your site, build a list of pages with that tag. This can be used for standard tag-based blog navigation.
MIT License
27 stars 6 forks source link

default template cannot be found #5

Closed svandragt closed 1 year ago

svandragt commented 8 years ago

It's not clear from the setting up instructions that a /templates/tags.html template is required. The readme says that the plugin ships with a default template. I've not checked this, but it definatelly does not get called correctly:

ValueError: The given value (u'~/Library/Caches/Lektor/packages/c2c6742dbf0a90d60bcba133cf9f3d16/templates/tags.html') is not below the source folder (u~/Dropbox/Lektor/vandragt.com')

philnelson commented 7 years ago

Creating lektor_tags_default_template.html under templates fixed this for me.

svandragt commented 7 years ago

Cheers Phil how did you figure that out?

paternal commented 6 years ago

The readme says that the plugin ships with a default template.

Moreover, this template is included in the wheel package, but:

dairiki commented 1 year ago

I think the issue is that shipping package data in a Python distribution requires that the data files live within a package's directory. As things stand, we do not have a package in which to include any package data: lektor_tags is a module (its source code is in a top-level file named lektor_tags.py), rather than a package (in which its code would be in lektor_tags/__init__.py).

(Currently, at least, it appears as if the default template is not included in the wheel at all. When lektor_tags is installed from source in editable mode, the default template can be found, however, if installed from the wheel, the template doesn't exist.)