views:

64

answers:

0

when I do this in google native django, it's ok but when I change this setting in gae-patch it seems that it is not working

 ...E\common\zip-packages\django-1.1.zip\django\utils\safestring.py in _proxy_method(self=u'\n<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01...rd 500 page.\n </p>\n</div>\n</body>\n</html>\n', *args=('gbk',), **kwargs={})
   79         """
   80         method = kwargs.pop('method')
   81         data = method(self, *args, **kwargs)
   82         if isinstance(data, str):
   83             return SafeString(data)
data undefined, method = <method 'encode' of 'unicode' objects>, self = u'\n<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01...rd 500 page.\n </p>\n</div>\n</body>\n</html>\n', args = ('gbk',), kwargs = {}

<type 'exceptions.UnicodeEncodeError'>: 'gbk' codec can't encode character u'\ufffd' in position 7270: illegal multibyte sequence
      args = ('gbk', u'\n<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Tr...standard 500 page.\n </p>\n</div>\n</body>\n</html>\n', 7270, 7271, 'illegal multibyte sequence')
      encoding = 'gbk'
      end = 7271
      message = ''
      object = u'\n<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Tr...standard 500 page.\n </p>\n</div>\n</body>\n</html>\n'
      reason = 'illegal multibyte sequence'
      start = 7270

what's the matter?