InvalidResponseError: headers must be str

Niklas Rosencrantz niklasro at gmail.com
Sat Dec 31 03:32:54 EST 2011


Thank you for the reply. I had the same error message before and it was resolved when I removed a casting of a header value from unicode to str. Now in this case I can't see where that happens or what causes the error. The full trace I'm experiencing now is

  File "/media/Lexar/montao/google/appengine/runtime/wsgi.py", line 129, in _StartResponse
    raise InvalidResponseError('headers must be str')
InvalidResponseError: headers must be str
INFO     2011-12-31 04:55:36,484 recording.py:372] Saved; key: __appstats__:034800, part: 137 bytes, full: 27325 bytes, overhead: 0.001 + 0.008; link: http://localhost:8080/_ah/stats/details?time=1325307334890
ERROR    2011-12-31 04:55:36,484 wsgi.py:186] 
Traceback (most recent call last):
  File "/media/Lexar/montao/google/appengine/runtime/wsgi.py", line 175, in Handle
    for chunk in result:
  File "/media/Lexar/montao/google/appengine/ext/appstats/recording.py", line 926, in appstats_wsgi_wrapper
    result = app(environ, appstats_start_response)
  File "/media/Lexar/montao/lib/webapp2/webapp2.py", line 1524, in __call__
    return self._internal_error(e)(environ, start_response)
  File "/media/Lexar/montao/lib/webapp2/webapp2.py", line 1522, in __call__
    return response(environ, start_response)
  File "/media/Lexar/montao/lib/webob/webob/__init__.py", line 2000, in __call__
    start_response(self.status, self.headerlist)
  File "/media/Lexar/montao/google/appengine/ext/appstats/recording.py", line 923, in appstats_start_response
    return start_response(status, headers, exc_info)
  File "/media/Lexar/montao/google/appengine/runtime/wsgi.py", line 129, in _StartResponse
    raise InvalidResponseError('headers must be str')
InvalidResponseError: headers must be str



More information about the Python-list mailing list