Before reworking this so as to not use urlllib, I tested it with threadsafe:false as per Waleed's suggestion. There was no difference. The larger number of characters still caused this one line of code to run 10x slower. However, switching to this statement got me back to the original performance even with the larger character set:
html = urllib.unquote(str(htmlEsc)) My ill-informed conclusion (tl;dr): The owner of urllib has noted that a complex and difficult re-write was needed to support Python3's "all strings are unicode" foundation. We unfortunately were asking the old version of urllib to process a large unicode string. Obviously not a good thing to do, and easily fixed by first converting to ascii via the str() function. Seems sort of a stupid mistake right now -- aren't they all. Live and learn I guess. Certainly worth remembering: ascii strings going into your entity come back as unicode strings, and not all of the Python 2.7 libs are fully optimized for unicode. -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
