> > Traceback (most recent call last): > > > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, > > in GetThumbnail > > Traceback (most recent call last): > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, > > in GetThumbnail > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line > > 917, in GetThumbnail > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line > > 917, in GetThumbnail > > self.Log(traceback.format_exc()) > > self.Log(traceback.format_exc()) > > self.Log(traceback.format_exc()) > > AttributeErrorself.Log(traceback.format_exc()) > > AttributeErrorself.Log(traceback.format_exc()) > > AttributeError: AttributeError: AttributeError: > > C:\Python\Projects\Warehouserclient_v3> > > > > > > And the last attributerror doesn't tell what attribute is missing. > > Probably I'll have to use a different library (pycurl, for example). But > > the error itself is getting more interesting. > > This makes me think self does not have a .Log() or the traceback > import is being overridden by something else that does not have > .format_exc(). Or possibly this is in a function that does not have a > self (maybe a typo in the function def?).
> Here you can find the example program and the original post. > > http://code.activestate.com/lists/python-list/617894/ I just looked at your source file on ActiveState and noticed that you do not import traceback. That is why you are getting the AttributeError. Now you should be getting a much better error once you import it :) Ramit Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology 712 Main Street | Houston, TX 77002 work phone: 713 - 216 - 5423 -- > -----Original Message----- > From: python-list-bounces+ramit.prasad=jpmorgan....@python.org > [mailto:python-list-bounces+ramit.prasad=jpmorgan....@python.org] On Behalf > Of Prasad, Ramit > Sent: Tuesday, March 20, 2012 3:52 PM > To: python-list@python.org > Subject: RE: urllib.urlretrieve never returns??? > > > Today I got a different error message printed on console (program > > started with python.exe) > > > > > > > > Unhandled exception in thread started by <bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4f85300> > > >>Unhandled exception in thread started by <bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4f85300> > > >>Unhandled exception in thread started by <bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4f85300> > > >>Unhandled exception in thread started by > > Traceback (most recent call last): > > > > Traceback (most recent call last): > > > > Traceback (most recent call last): > > <bound method FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy > > of <Swig Object of type 'wxPanel *' at 0x4f85300> > > >> File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, > > in GetThumbnail > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, > > in GetThumbnail > > File "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, > > in GetThumbnail > > > > sys.excepthook is missing > > Traceback (most recent call last): > > > > I have never seen a traceback like this before. I didn't install any > > excepthook myself. > > > > Program is using wxPython, socket, threads, threading, PIL. > > > > Here is something even more strange. If I click on the button three > > times, then absolutely nothing gets printed on stdout. However, if I > > close the program with file/exit (actually, calling > > wx.PySimpleApp.ExitMainLoop) then suddenly three stack traces are > > printed on stdout, all lines mixed up: > > > > Maybe in self.Log you should add a sys.stdout.flush and > sys.stderr.flush(). I am not very familiar with stdin/out but > maybe it will help. > > > Unhandled exception in thread started by <bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4fb530 > > 0> > > >>Unhandled exception in thread started by Unhandled exception in > > thread started by <bound method FrameLocEdit.GetThumbnail of > > <locedit.FrameLocEdit; proxy of <Swig Object of type 'wxPanel *' at > > 0x4fb5300> > > >>Unhandled exception in thread started by Unhandled exception in > > thread started by <bound method FrameLocEdit.GetThumbnail of > > <locedit.FrameLocEdit; proxy of <Swig Object of type 'wxPanel *' at > > 0x4fb5300> > > >>Traceback (most recent call last):<bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4fb5300> > > >>Traceback (most recent call last):<bound method > > FrameLocEdit.GetThumbnail of <locedit.FrameLocEdit; proxy of <Swig > > Object of type 'wxPanel *' at 0x4fb5300> > > >>Traceback (most recent call last): File > > "C:\Python\Projects\Warehouserclient_v3\locedit.py", line 917, in > > GetThumbnail > > > > > > > > > Also tried to use an invalid file (that should return with HTTP 404 not > > found) but the effect is exactly the same. Nothing is printed on stdout > > until I try to close the program (stop wxPython's mainloop). Then all > > previously threads throw an AttributeError and all of them print a stack > > trace (at the same time, lines mixed up). > > > > I'll be experimenting with pyCurl now. > > > Ramit > > > Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology > 712 Main Street | Houston, TX 77002 > work phone: 713 - 216 - 5423 > > -- > > This email is confidential and subject to important disclaimers and > conditions including on offers for the purchase or sale of > securities, accuracy and completeness of information, viruses, > confidentiality, legal privilege, and legal entity disclaimers, > available at http://www.jpmorgan.com/pages/disclosures/email. > -- > http://mail.python.org/mailman/listinfo/python-list -- http://mail.python.org/mailman/listinfo/python-list