summaryrefslogtreecommitdiff
path: root/django/core/handlers/modpython.py
diff options
context:
space:
mode:
authorLuke Plant <L.Plant.98@cantab.net>2011-06-09 23:15:42 +0000
committerLuke Plant <L.Plant.98@cantab.net>2011-06-09 23:15:42 +0000
commitdb2f9bfae173b565215a9f7320d7a45d0532f2fe (patch)
treed558e4e6b16aadfa1cdc39cfce3d882f774e5153 /django/core/handlers/modpython.py
parentdff31de20aac85e4f4834c2466762cbf23fc0a7b (diff)
Fixed #16178 - Cleanup request classes' `__repr__()`
Thanks to julien for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16350 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/core/handlers/modpython.py')
-rw-r--r--django/core/handlers/modpython.py26
1 files changed, 0 insertions, 26 deletions
diff --git a/django/core/handlers/modpython.py b/django/core/handlers/modpython.py
index f0c77015b4..5affea45c5 100644
--- a/django/core/handlers/modpython.py
+++ b/django/core/handlers/modpython.py
@@ -45,32 +45,6 @@ class ModPythonRequest(http.HttpRequest):
self._stream = self._req
self._read_started = False
- def __repr__(self):
- # Since this is called as part of error handling, we need to be very
- # robust against potentially malformed input.
- try:
- get = pformat(self.GET)
- except:
- get = '<could not parse>'
- if self._post_parse_error:
- post = '<could not parse>'
- else:
- try:
- post = pformat(self.POST)
- except:
- post = '<could not parse>'
- try:
- cookies = pformat(self.COOKIES)
- except:
- cookies = '<could not parse>'
- try:
- meta = pformat(self.META)
- except:
- meta = '<could not parse>'
- return smart_str(u'<ModPythonRequest\npath:%s,\nGET:%s,\nPOST:%s,\nCOOKIES:%s,\nMETA:%s>' %
- (self.path, unicode(get), unicode(post),
- unicode(cookies), unicode(meta)))
-
def get_full_path(self):
# RFC 3986 requires self._req.args to be in the ASCII range, but this
# doesn't always happen, so rather than crash, we defensively encode it.