[Freewx-maint] Bug#775457: python-wxgtk3.0: wx.lib.infoframe.PyInformationalMessagesFrame modifies tempfile.tempdir

Jakub Wilk jwilk at debian.org
Thu Jan 15 21:15:17 UTC 2015


Package: python-wxgtk3.0
Version: 3.0.1.1+dfsg-2

The write method of the wx.lib.infoframe.PyInformationalMessagesFrame 
class does this:

                    tempfile.tempdir = self.dir
                    filename = os.path.abspath(tempfile.mktemp ())

...and does not restore the previous value of tempfile.tempdir 
afterwards.

This is not a nice thing to do in a library code, since tempdir affects 
calls to the tempfile functions from the whole program, not only this 
module. Also, it's completely unnecessary, because tempfile.mktemp() 
takes "dir" as an optional argument.

-- 
Jakub Wilk



More information about the Freewx-maint mailing list