urllib.urlretrieve never returns??? [SOLVED] - workaround

Prasad, Ramit ramit.prasad at jpmorgan.com
Tue Mar 20 22:01:58 CET 2012


> Everything works perfectly, in all modes: console, no console, started
> directly and started in separate thread.
> 
> So the problem with urllib must be. Maybe wxPython installs some except
> hooks, or who knows? If somebody feels up to it, I can start narrowing
> down the problem to the smallest possible application. But only if
> someone knows how to debug core code because I don't. Otherwise I'll
> just use pyCURL.

Have you tried urllib2? Have you tried a small program without using wx?

To be honest, I doubt the problem is wx or urllib as they are both fairly
broadly used. Try to come up with an example that is as minimal as possible. 

>>> imgurl = "http://www.shopzeus.hu/thumbnail.php?width=200&image=pyramid/PP0830.jpg"
>>> urllib.urlretrieve( imgurl )
('c:\\[...]\\tmpkhixgt.php', <httplib.HTTPMessage instance at 0x0F2D75A8>)

And I have Windows 7 64 with Python 2.6.6 (32 bit) and wx installed.

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.  



More information about the Python-list mailing list