When someone (dumb, like me) returns a string from the application they pass to WSGIServer, warn the user that it's dumb, and broken.
i.e.
# super-simple app
def myapp
return "This is my string ... I'm nestled among a big list of other returns, so I'm hard to find."
# instead of
# return ["This makes WSGIServer do happy things"]
# Somewhere in here this should warn ... Returning strings is dumb, and wrong.
WSGIServer(myapp).run()
I just spent 4 hours figuring that out, so I thought I'd share. (I suppose an assert might be grand, especially since you can -O them out)
Alternatively, WSGIServer could check to see if it's getting a string, and not interpret it as an interable ...
Cheers