I wrote as following: content=urllib2.urlopen("http://www.sdfagfa.org/asasg/a.zip").read() f=open("d:\\a.zip",'a+',1) f.writelines(content) the zip file has been download to my machine,but when be unzip , error occurs: " there is an error at the end of the file"