Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix template cache #403

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

fix template cache #403

wants to merge 1 commit into from

Conversation

jeriox
Copy link
Contributor

@jeriox jeriox commented Mar 27, 2021

No description provided.

@jeriox jeriox requested a review from felixrindt March 27, 2021 14:40
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.09%) to 88.708% when pulling 1d1e62d on bugfix/template-cache into 2d6b109 on main.

def save(self, commit=True):
cache_key = make_template_fragment_key("eventtype_colors")
cache.delete(cache_key)
return super().save(commit)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use a post_save signal? To me, the place where the css is generated seems like a more fitting place for this to live.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

couldn't get this to work, the cache is not invalidated with the same code that works here.

@jeriox jeriox added the [C] bug Something isn't working label Apr 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C] bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants