TkInter workaround runtime setting

Last edited on

TkInter auto-generates the Tk-Path that Squish uses for identifying objects and bases that apparently on the “id” of the Python objects that relate to the widgets. This means that on each run the Tk-Path for a given Tk widget is different.

There is a workaround in Squish/Tk for this case, but it is not enabled by default.

To enable the workaround one can either create $HOME/.squish/ver1/tkwrapper.ini (Unix) or %APPDATA%\froglogic\Squish\ver1\tkwrapper.ini (Windows) with this content:

[Tk Wrapper]

As an alternative it is also possible to put the above into a text file at another location and register that as a wrapper configuration file via squishserver --config setConfig <AUT> <inifile>.