HttpRequest __repr__ too verbose
When working from a shell, printing request always fills my terminal with unneeded information. I would like to type locals() within a view without garbage all over my screen and type request.META, request.POST, etc if I would like to see more details. My patch replaces GET, POST, COOKIES, and META with the method and URL.
Attachments
(3)
- requestrepr.diff
(3.3 KB
) - added by Cody Soyland <codysoyland@…> 15 years ago.
- Replaces output of request.repr with the method and URL
- requestrepr.2.diff
(5.5 KB
) - added by Cody Soyland <codysoyland@…> 15 years ago.
- This patch does handles parse errors in get_full_path and adds request metadata to error emails.
- requestrepr.3.diff
(5.5 KB
) - added by Cody Soyland <codysoyland@…> 15 years ago.
- The only difference from the last patch is that this one uses an unqualified exception catcher.
Download all attachments as:
.zip
Change History
(12)
Cc: |
codysoyland@… added
|
Needs tests: |
set
|
Triage Stage: |
Unreviewed → Accepted
|
Severity: |
→ Normal
|
Type: |
→ New feature
|
Component: |
Uncategorized → HTTP handling
|
Easy pickings: |
unset
|
UI/UX: |
unset
|
Needs tests: |
unset
|
Owner: |
changed from nobody to Berker Peksag
|
Status: |
new → assigned
|
Version: |
1.1 → master
|
Triage Stage: |
Accepted → Ready for checkin
|
Resolution: |
→ fixed
|
Status: |
assigned → closed
|
Replaces output of request.repr with the method and URL