By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,813 Members | 1,130 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,813 IT Pros & Developers. It's quick & easy.

BadStatusLine error

P: n/a
Jim
Hi

I get a BadStatusLine error (indicated below). Can anyone help with
how to
catch error in code before abort?

Thanks
Jim

Traceback (most recent call last):

File
"C:\Python25\Lib\site-packages\pythonwin\pywin\framework
\scriptutils.py",
line 310, in RunScript
exec codeObject in __main__.__dict__
File "C:Lookup.py", line 103, in <module>
contents = urllib2.urlopen(url).read()
File "C:\Python25\lib\urllib2.py", line 121, in urlopen
return _opener.open(url, data)
File "C:\Python25\lib\urllib2.py", line 374, in open
response = self._open(req, data)
File "C:\Python25\lib\urllib2.py", line 392, in _open
'_open', req)
File "C:\Python25\lib\urllib2.py", line 353, in _call_chain
result = func(*args)
File "C:\Python25\lib\urllib2.py", line 1100, in http_open
return self.do_open(httplib.HTTPConnection, req)
File "C:\Python25\lib\urllib2.py", line 1073, in do_open
r = h.getresponse()
File "C:\Python25\lib\httplib.py", line 924, in getresponse
response.begin()
File "C:\Python25\lib\httplib.py", line 385, in begin
version, status, reason = self._read_status()
File "C:\Python25\lib\httplib.py", line 349, in _read_status
raise BadStatusLine(line)
BadStatusLine

Jun 27 '08 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Jim wrote:
Hi

I get a BadStatusLine error (indicated below). Can anyone help with
how to
catch error in code before abort?
http://docs.python.org/tut/node10.html

Diez
Jun 27 '08 #2

P: n/a
Jim
On May 28, 11:24 am, "Diez B. Roggisch" <de...@nospam.web.dewrote:
Jim wrote:
Hi
I get a BadStatusLine error (indicated below). Can anyone help with
how to
catch error in code before abort?

http://docs.python.org/tut/node10.html

Diez
Thanks Diez docs help. Jim

Jun 27 '08 #3

This discussion thread is closed

Replies have been disabled for this discussion.