i use urllib2 to open the websites and get info. it works for a while, then will be stopped, the error in idle is http error 404 no such domain. but i just changed the parameters in the url by looping, and i can open it in ie or firefox. any one have any idea to deal with it? if I running 2 more similar programs in command line at same time, them will be stopped more sooner.
my code is running in python 2.5 + tor.
Thks a lot.
"Traceback (most recent call last):
File "C:\Documents and Settings\XXXX\Desktop\NZ_New - Copy\NZ 1- 40 14022009\nz_new1.py", line 191, in <module>
Main()
File "C:\Documents and Settings\XXXX\Desktop\NZ_New - Copy\NZ 1- 40 14022009\nz_new1.py", line 69, in Main
Process(1)
File "C:\Documents and Settings\XXXX\Desktop\NZ_New - Copy\NZ 1- 40 14022009\nz_new1.py", line 141, in Process
input_page = urllib2.urlopen(req)
File "C:\Python25\lib\urllib2.py", line 121, in urlopen
return _opener.open(url, data)
File "C:\Python25\lib\urllib2.py", line 380, in open
response = meth(req, response)
File "C:\Python25\lib\urllib2.py", line 491, in http_response
'http', request, response, code, msg, hdrs)
File "C:\Python25\lib\urllib2.py", line 418, in error
return self._call_chain(*args)
File "C:\Python25\lib\urllib2.py", line 353, in _call_chain
result = func(*args)
File "C:\Python25\lib\urllib2.py", line 499, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 404: No such domain"