Hi Tom,

I am trying to run your CSW tests but I'm having proxy problems - I get the 
following error:

File "csw_nlr.txt", line 2, in csw_nlr.txt
Failed example:
    c = CatalogueServiceWeb('http://geomatics.nlr.nl/excat/csw')
Exception raised:
    Traceback (most recent call last):
      File "/usr/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest csw_nlr.txt[1]>", line 1, in <module>
        c = CatalogueServiceWeb('http://geomatics.nlr.nl/excat/csw')
      File "/home/dom/eclipsewkspace/OWSLib/owslib/csw.py", line 77, in 
__init__
        self.response = util.http_post(self.url, self.request, self.lang)
      File "/home/dom/eclipsewkspace/OWSLib/owslib/util.py", line 138, in 
http_post
        h.endheaders()
      File "/usr/lib/python2.5/httplib.py", line 860, in endheaders
        self._send_output()
      File "/usr/lib/python2.5/httplib.py", line 732, in _send_output
        self.send(msg)
      File "/usr/lib/python2.5/httplib.py", line 699, in send
        self.connect()
      File "/usr/lib/python2.5/httplib.py", line 683, in connect
        raise socket.error, msg
    error: (111, 'Connection refused')


This is because I'm going through a proxy. However I haven't had problems with 
urllib. Could you use urllib to make the post request instead as it picks up 
proxy environment variables whereas httplib doesn't do this.

The python docs say the following about httplib:  "This module defines classes 
which implement the client side of the HTTP and HTTPS protocols. It is 
normally not used directly — the module urllib uses it to handle URLs that 
use HTTP and HTTPS."
http://docs.python.org/library/httplib.html

Cheers,
Dom
_______________________________________________
Community mailing list
[email protected]
http://lists.gispython.org/mailman/listinfo/community

Reply via email to