Skip to content

THUMBNAIL_NAMER setting does not have any effect when using filer #1093

Open
@benzkji

Description

@benzkji

When dealing with SEO (SmileyChris/easy-thumbnails#474) or when one just wants a different THUMBNAIL_NAMER (SmileyChris/easy-thumbnails#492), there seems to be no luck with the filer.

There is the ThumbnailerNameMixin, that has it's own get_thumbnail_name() method, where the naming is fixed, as said there "A version of Thumbnailer.get_thumbnail_name that produces a
reproducible thumbnail name that can be converted back to the original
filename. : https://github.com/divio/django-filer/blob/006a1cfbdb5f61b6725b7675c7f9117e85b5d367/filer/utils/filer_easy_thumbnails.py#L32 That mixin is used for FilerThumbnailer, that is then created here: https://github.com/divio/django-filer/blob/006a1cfbdb5f61b6725b7675c7f9117e85b5d367/filer/models/abstract.py#L175 . I do not really get how this all works and interacts with easy_thumbnails. But the question remains: Why does filer need to override the namer, and get back to the original from the thumbnail? Normally, it would be enough to get the thumbnails, when for example deleting a file, so no orphaned thumbs are around?

And finally, am I missing something in the docs, and setting a custom namer is already possible?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions