summaryrefslogtreecommitdiff
path: root/morphlib/morphologyfactory.py
diff options
context:
space:
mode:
authorJannis Pohlmann <jannis.pohlmann@codethink.co.uk>2012-04-20 11:11:46 +0100
committerJannis Pohlmann <jannis.pohlmann@codethink.co.uk>2012-04-20 11:15:46 +0100
commit9ee4e4c57624cfee21d3bcc132f780bff04a59c4 (patch)
tree0d68a328d2b2e051de108008a7b552fbce790f59 /morphlib/morphologyfactory.py
parentcc84de3d6ccd63e1d53a2f66815ff1f192a89d36 (diff)
downloadmorph-9ee4e4c57624cfee21d3bcc132f780bff04a59c4.tar.gz
Drop httplib2 in RemoteRepoCache, use custom HeadRequest and urllib2.
With a neat little trick, urllib2 can be made to only perform a HEAD request in urllib2.urlopen(). This is done by creating a dedicated HeadRequest class for HEAD requests and by passing such a HeadRequest to urllib2.urlopen(). This also means we no longer have to check the response status ourselves again as urllib2 will raise an exception on negative HTTP responses like 404 or 500.
Diffstat (limited to 'morphlib/morphologyfactory.py')
0 files changed, 0 insertions, 0 deletions