When trying start a simple push queue task on Google Appengine Python27 SDK (which ran fine on Python 2.5) I'm now getting a traceback ending with:
File "c:\program files\google\google_appengine\google\appengine\api\taskqueue\
taskqueue_stub.py", line 1662, in ExecuteTask connection.putheader(header_key, header_value)
File "C:\Python27\lib\httplib.py", line 924, in putheader str = '%s: %s' % (header, '\r\n\t'.join(values))
TypeError: sequence item 0: expected string, int found
The TypeError above occurs for
header = 'Content-Length'
values = (112,)
That should obviously be values=('112',)
Thankful for any advice,
Mort
Looks like a bug and it has been reported: Issue 6460: Development Server - taskqueue stub type error
To get it working you'll need to patch the SDK manually, file: google/appengine/api /taskqueue/taskqueue_stub.py , line which looks like:
headers.append(('Content-Length', len(task.body())))
fix to:
headers.append(('Content-Length', str(len(task.body()))))
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.