Re: [Tutor] httplib2.RelativeURIError: Only absolute URIs are allowed. uri

2011-10-16 Thread Steven D'Aprano
pierre dagenais wrote: Isn't "file:///home/pierre/bookmarks.html" a valid URI? It works fine with urllib, why not with httplib2? "file://..." is not a HTTP resource. -- Steven ___ Tutor maillist - Tutor@python.org To unsubscribe or change subs

[Tutor] httplib2.RelativeURIError: Only absolute URIs are allowed. uri

2011-10-16 Thread pierre dagenais
Hi, I'm running python 3.2 on Ubuntu 11.04 and have a problem with httplib2. I'm not sure if it's my ignorance or a bug in the code. This code works: #! /usr/bin/python3.2 import urllib.request sock = urllib.request.urlopen("file:///home/pierre/bookmarks.html") htmlSource = sock.read() sock.