Message5437

Author julyzergcn
Recipients julyzergcn
Date 2010-01-14.07:23:41
SpamBayes Score 2.6336534e-06
Marked as misclassified No
Message-id <1263453823.35.0.0970809377185.issue1542@psf.upfronthosting.co.za>
In-reply-to
Content
urllib.urlretrieve cannot close connection automatically.
also, urllib.urlopen cannot close.
e.g.
if I want to download a file from a ftp server, write one line like this,
  import urllib
  urllib.urlretrieve('ftp://user:pass@hostname/fdir', 'localname')
after the file is download, the connection cannot close automatically, but Python2.5 can. 
also, the following code can not close the connection as well.
  import urllib
  f = urllib(''ftp://user:pass@hostname/fdir')
  print f.read()
  f.close()

would it be possible to make Jython close the connection like Python?
thanks
History
Date User Action Args
2010-01-14 07:23:43julyzergcnsetrecipients: + julyzergcn
2010-01-14 07:23:43julyzergcnsetmessageid: <1263453823.35.0.0970809377185.issue1542@psf.upfronthosting.co.za>
2010-01-14 07:23:43julyzergcnlinkissue1542 messages
2010-01-14 07:23:42julyzergcncreate