From 236215633ae2feddfd6f9799692df89c1a0d715b Mon Sep 17 00:00:00 2001 From: "https://www.google.com/accounts/o8/id?id=AItOawn46FqvVCgiNqPzeLTvAgSgLn7NfsaDzms" Date: Mon, 12 May 2014 09:31:04 -0400 Subject: --- ...___codec_can__39__t_encode_character__34__.mdwn | 36 ++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 doc/bugs/rst_plugin_fails_with___34__uncaught_exception:___39__ascii__39___codec_can__39__t_encode_character__34__.mdwn (limited to 'doc/bugs') diff --git a/doc/bugs/rst_plugin_fails_with___34__uncaught_exception:___39__ascii__39___codec_can__39__t_encode_character__34__.mdwn b/doc/bugs/rst_plugin_fails_with___34__uncaught_exception:___39__ascii__39___codec_can__39__t_encode_character__34__.mdwn new file mode 100644 index 000000000..ae077bb1d --- /dev/null +++ b/doc/bugs/rst_plugin_fails_with___34__uncaught_exception:___39__ascii__39___codec_can__39__t_encode_character__34__.mdwn @@ -0,0 +1,36 @@ + I get this error when enabling the `rst` plugin. I am running IkiWiki +3.20130904.1ubuntu1 on Ubuntu 14.04 in a non-English UTF-8 locale; the +pages can also contain characters in UTF-8 encoding. + + uncaught exception: 'ascii' codec can't encode character u'\xa9' in position 13: ordinal not in range(128) + Traceback (most recent call last): + File "/usr/lib/ikiwiki/plugins/proxy.py", line 309, in run + self._in_fd, self._out_fd) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 192, in handle_rpc + ret = self._dispatcher.dispatch(method, params) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 84, in dispatch + return self._dispatch(method, params) + File "/usr/lib/python2.7/SimpleXMLRPCServer.py", line 420, in _dispatch + return func(*params) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 253, in hook_proxy + "{0} hook `{1}' returned: [{2}]".format(type, name, ret)) + UnicodeEncodeError: 'ascii' codec can't encode character u'\xa9' in position 13: ordinal not in range(128) + + Traceback (most recent call last): + File "/usr/lib/ikiwiki/plugins/rst", line 86, in + proxy.run() + File "/usr/lib/ikiwiki/plugins/proxy.py", line 317, in run + self.error('uncaught exception: {0}\n{1}'.format(e, tb)) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 298, in error + self.rpc('error', msg) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 233, in rpc + *args, **kwargs) + File "/usr/lib/ikiwiki/plugins/proxy.py", line 173, in send_rpc + raise GoingDown() + proxy.py.GoingDown + +A fix is akin to the one for +: change +`...format(type, name, ret)` in `proxy.py` line 253 to `format(type, +name, repr(ret))` (which should not hurt since it's a message +for debugging purposes only). -- cgit v1.2.3