From: Anders Kaseorg Date: Tue, 30 Jun 2009 23:06:54 +0000 (-0400) Subject: Apparently shlex.split doesn’t work on unicode. X-Git-Url: https://snippets.scripts.mit.edu/gitweb.cgi/Scripts/git/.git/commitdiff_plain/f503b22f82e2cdc73785b30693401c99fbdc3d75 Apparently shlex.split doesn’t work on unicode. --- diff --git a/TracZephyrPlugin/ZephyrPlugin.py b/TracZephyrPlugin/ZephyrPlugin.py index fe46914..87c8762 100644 --- a/TracZephyrPlugin/ZephyrPlugin.py +++ b/TracZephyrPlugin/ZephyrPlugin.py @@ -11,7 +11,7 @@ class ZephyrPlugin(Component): zclass = self.config.get('ZephyrPlugin', 'class') if zclass == '': return - command = shlex.split(self.config.get('ZephyrPlugin', 'command')) + command = shlex.split(self.config.get('ZephyrPlugin', 'command').encode('utf-8')) if not command: command = ['zwrite', '-q', '-l', '-d'] p = subprocess.Popen(command +