def get_query_str(query: Type[QueryDict], max_length: int = <NUM_LIT>) -> str:
query_dict = query.copy()<EOL>query_dict.pop('<STR_LIT:password>', None)<EOL>query_dict.pop(settings.AXES_PASSWORD_FORM_FIELD, None)<EOL>query_str = '<STR_LIT:\n>'.join(<EOL>f'<STR_LIT>'<EOL>for key, value<EOL>in query_dict.items()<EOL>)<EOL>return query_str[:max_length]<EOL>
Turns a query dictionary into an easy-to-read list of key-value pairs.

If a field is called either ``'password'`` or ``settings.AXES_PASSWORD_FORM_FIELD`` it will be excluded.

The length of the output is limited to max_length to avoid a DoS attack via excessively large payloads.