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

Need information on mocking context processors #134

Closed
2 tasks done
thibaudcolas opened this issue Nov 2, 2020 · 2 comments
Closed
2 tasks done

Need information on mocking context processors #134

thibaudcolas opened this issue Nov 2, 2020 · 2 comments
Labels
question Further information is requested
Milestone

Comments

@thibaudcolas
Copy link
Member

thibaudcolas commented Nov 2, 2020

It’s unclear whether mocking context processors is supported, and if so how.

If it’s not supported, we need to document this at the very least.

Detailed feedback from @ababic:

Context processors are potentially misused/overused to get around limitations

For example, I've seen forms, various bits of text and other variables added via context processors to make things available when rendering via the pattern library. This is fine to a degree, but there could be better options (like using wagtail sitesettings) that are overlooked because they are more difficult to integrate with the pattern library

Which terms did you search for in the docs and issues?

  • In the documentation I searched for: context processors
  • In the issues / pull requests, I searched for: context processors
@thibaudcolas thibaudcolas added the question Further information is requested label Nov 2, 2020
@thibaudcolas thibaudcolas added this to the Nice to have milestone Nov 2, 2020
@ababic
Copy link
Contributor

ababic commented Nov 3, 2020

Hey @thibaudcolas. This is more a symptom, rather than a problem in itself. The issue is that adding a context processor is sometimes the only option to inject complex objects into the template context. I think there have been some improvements in this area since I raised this.

@thibaudcolas
Copy link
Member Author

Thank you @ababic, re-reading this I did completely misunderstand this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants