New submission from Serhiy Storchaka: Tk.split() doesn't work with nested Unicode strings, but works with nested bytes.
>>> import tkinter >>> t = tkinter.Tcl() >>> t.split('a {b c}') ('a', ('b', 'c')) >>> t.split(b'a {b c}') ('a', ('b', 'c')) >>> t.split(('a {b c}',)) ('a {b c}',) >>> t.split((b'a {b c}',)) (('a', ('b', 'c')),) I think this is unintentional. Here is a patch which processes strings inside a tuple as bytes objects. It also adds tests for Tk.splitline() and Tk.split(). ---------- components: Tkinter files: tkinter_split_nested_unicode.patch keywords: patch messages: 190359 nosy: serhiy.storchaka priority: normal severity: normal stage: patch review status: open title: Tk.split() doesn't work with nested Unicode strings type: behavior versions: Python 3.3, Python 3.4 Added file: http://bugs.python.org/file30426/tkinter_split_nested_unicode.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue18101> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com