Novice: Method call for decompress gzip file

Patrick Wang pwang at uclink.berkeley.edu
Sat Dec 28 16:34:13 EST 2002


Hi:
I have written a program to pummerling www.hoovers.com to get some data
systematically.
I also used a sniff program to detect what information I need to send. The
response is OK with len 10200.

CONTENT encoding is GZIP, however I had problem when I tried to decompress,
error msg is -3, unknown compressing method.

Can anybody help?
Thanks

Pat

============================================================================
=================
conn1.request('GET','/cgi-bin/hol_search?siteid=HBN&which=company&query_stri
ng=Amgen+Inc&dir_top_id=7',None,headers)

response1 = conn1.getresponse()
len = response1.getheader('Content-Length')
print len
data1 =response1.read()
print response1.status, response1.reason

data2 = zlib.decompress(data1)
**************************************?????????????

-----Original Message-----
From: python-list-admin at python.org
[mailto:python-list-admin at python.org]On Behalf Of Luca Bruderer
Sent: Saturday, December 28, 2002 1:09 PM
To: python-list at python.org
Subject: Algorithm for extracting the prime factors of an integer


Hi

I'm wondering which is the best algorithm to do this.

Greetings
Luca


--
http://mail.python.org/mailman/listinfo/python-list





More information about the Python-list mailing list