get_sample_data still broken on v.1.1.x

It appears that cbook.get_sample_data is still broken, at least in some configurations.  I start with an empty cache (custom MPLCONFIGDIR) and run an example that requires the sample data once, and it pulls from github.  All is well.  When I run the example a second time, it get a failure (traceback below)

Running in v.1.1.x branch with commit 0c7f83d824dcecfee182db7eef7a3727e5feaa2f on opensuse python2.7 64 bit.  herre is the --verbose-debug output:




# remove the sample_data cache
johnh@lettuce:doc> rm -rf /export/home/johnh/.matplotlib.linux/sample_data

# first run is OK
johnh@lettuce:doc> MPLCONFIGDIR=/export/home/johnh/.matplotlib.linux PYTHONPATH=/export/home/johnh/devlinux/lib64/python2.7/site-packages/ python ../examples/pylab_examples/image_demo3.py -dGTKAgg --verbose-debug
$HOME=/home/titan/johnh
matplotlib data path /export/home/johnh/devlinux/lib64/python2.7/site-packages/matplotlib/mpl-data
loaded rc file /export/home/johnh/matplotlib.matplotlib/doc/matplotlibrc
matplotlib version 1.1.0
verbose.level debug
interactive is False
platform is linux2
loaded modules: ['heapq', snip...]
CONFIGDIR=/export/home/johnh/.matplotlib.linux
Using fontManager instance from /export/home/johnh/.matplotlib.linux/fontList.cache
backend GTKAgg version 2.22.0
ViewVCCachedServer: files listed in cache.pck: set([])
ViewVCCachedServer: files in cache directory: set([])
ViewVCCachedServer: retrieving https://raw.github.com/matplotlib/sample_data/master/lena.jpg
ViewVCCachedServer: received response 200: OK



# second run crashes
johnh@lettuce:doc> MPLCONFIGDIR=/export/home/johnh/.matplotlib.linux PYTHONPATH=/export/home/johnh/devlinux/lib64/python2.7/site-packages/ python ../examples/pylab_examples/image_demo3.py -dGTKAgg --verbose-debug
$HOME=/home/titan/johnh
matplotlib data path /export/home/johnh/devlinux/lib64/python2.7/site-packages/matplotlib/mpl-data
loaded rc file /export/home/johnh/matplotlib.matplotlib/doc/matplotlibrc
matplotlib version 1.1.0
verbose.level debug
interactive is False
platform is linux2
loaded modules: ['heapq', snip...]
CONFIGDIR=/export/home/johnh/.matplotlib.linux
Using fontManager instance from /export/home/johnh/.matplotlib.linux/fontList.cache
backend GTKAgg version 2.22.0
ViewVCCachedServer: files listed in cache.pck: set(['/export/home/johnh/.matplotlib.linux/sample_data/lena.jpg'])
ViewVCCachedServer: files in cache directory: set(['/export/home/johnh/.matplotlib.linux/sample_data/lena.jpg', '/export/home/johnh/.matplotlib.linux/sample_data/cache.pck'])
ViewVCCachedServer: retrieving https://raw.github.com/matplotlib/sample_data/master/lena.jpg
Traceback (most recent call last):
  File "../examples/pylab_examples/image_demo3.py", line 10, in <module>
    datafile = cbook.get_sample_data('lena.jpg')
  File "/export/home/johnh/devlinux/lib64/python2.7/site-packages/matplotlib/cbook.py", line 688, in get_sample_data
    return myserver.get_sample_data(fname, asfileobj=asfileobj)
  File "/export/home/johnh/devlinux/lib64/python2.7/site-packages/matplotlib/cbook.py", line 617, in get_sample_data
    response = self.opener.open(url)
  File "/usr/lib64/python2.7/urllib2.py", line 391, in open
    response = self._open(req, data)
  File "/usr/lib64/python2.7/urllib2.py", line 409, in _open
    '_open', req)
  File "/usr/lib64/python2.7/urllib2.py", line 369, in _call_chain
    result = func(*args)
  File "/usr/lib64/python2.7/urllib2.py", line 1197, in https_open
    return self.do_open(httplib.HTTPSConnection, req)
  File "/usr/lib64/python2.7/urllib2.py", line 1158, in do_open
    h.request(req.get_method(), req.get_selector(), req.data, headers)
  File "/usr/lib64/python2.7/httplib.py", line 946, in request
    self._send_request(method, url, body, headers)
  File "/usr/lib64/python2.7/httplib.py", line 986, in _send_request
    self.putheader(hdr, value)
  File "/usr/lib64/python2.7/httplib.py", line 924, in putheader
    str = '%s: %s' % (header, '\r\n\t'.join(values))
TypeError: sequence item 0: expected string, NoneType found
johnh@lettuce:doc>