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 session filters is None from request session #1177
Fix session filters is None from request session #1177
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please format code with black.
Can you provide test demonstrating the issue and fixing the crash? Or instruction how this crash can be reproduced from admin UI? |
I set any field in User Accounts menu of search list, then I clear the search list. This is OK. |
Can you add test to |
Yes, I will add the test later. |
Done. |
I try my best to fix this bug. My english not good. |
You are doing great, don't worry! 👍 I am just wondering if you know which line in |
I saw this line, but I am trying to wrap my mind around it. Where |
The def get_filtering_method_to_use(self, methods):
for method in ("GET", "session"):
if methods.get(method):
return methods.get(method) The Maybe |
Hello @ChandlerBent I've cloned your PR locally, investigated it and found where the bug lies ;)
Actual fix is adding the
|
Thank you for making Misago better! Your commits will land as #1190, I'll also backport the fix to Misago 0.19 today or tomorrow! |
Heads up @ChandlerBent I've noticed this bug was introduced on master branch when I was fixing If you are running Misago master on production, please don't - we don't support that. |
If get session filters is
None
from request session, the search form will be raise no attribute 'cleaned_data' exception.