Issue 934418: nametowidget throws TypeError for Tcl_Objs (original) (raw)
In some rare cases with Python 2.3.3 and Tcl/Tck 8.4.5, in particular in tk_focusNext(), self.tk.call returns a Tcl_Obj instead of a string and then nametowidget() throws a TypeError when it tries to check if the first character is a period or not. Since Tcl/Tk is only going to get more Tcl_Obj-ectified, the best solution is to not change tk_focusNext(), but to add two lines to nametowidget():
if not isinstance(name, str): name = str(name)