Opened 4 years ago

Closed 4 years ago

#15686 closed (duplicate)

Bug in core.handlers.wsgi.py, variable is used before assignment

Reported by: vak Owned by: nobody
Component: Core (Other) Version: 1.3
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

"request" is indeed used before assignment near line 264:

try:
  request = self.request_class(environ)
except UnicodeDecodeError:
  logger.warning('Bad Request (UnicodeDecodeError): %s' % request.path,
                  exc_info=sys.exc_info(),
...

Details:

Traceback (most recent call last):
File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/wsgi.py", line 264, in call
logger.warning('Bad Request (UnicodeDecodeError): %s' % request.path,
UnboundLocalError: local variable 'request' referenced before assignment
mod_wsgi (pid=25127): Exception occurred processing WSGI script '[....]wsgi'.

Change History (1)

comment:1 Changed 4 years ago by jezdez

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #15672.

Note: See TracTickets for help on using tickets.
Back to Top