<div dir="ltr"><div>I'm getting a internal error when fetching a tile from the WMTS KVP service using QGIS.  </div><div>From some older posting it appears that there can be a issue with the client application incorrectly requesting the tilematrix as a string (1 instead of 01).  However I would expect this to work at higher tilematrixes > 10 which it doesn't</div><div><br></div><div>The error is below:</div><div><br></div><div><br></div><div>Traceback (most recent call last):</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/wsgiapp.py", line 189, in __call__</div><div>    resp = self.handlers[handler_name].handle(req)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/service/ows.py", line 38, in handle</div><div>    return self.services[service].handle(req)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/service/base.py", line 30, in handle</div><div>    return handler(parsed_req)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/service/wmts.py", line 93, in tile</div><div>    tile = tile_layer.render(request, coverage=limited_to, decorate_img=decorate_img)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/service/tile.py", line 308, in render</div><div>    dimensions=dimensions, with_metadata=True)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/cache/tile.py", line 110, in load_tile_coord</div><div>    self.cache.load_tile(tile, with_metadata)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/cache/riak.py", line 132, in load_tile</div><div>    res = self._get_object(tile.coord)</div><div>  File "/usr/lib64/python2.7/site-packages/mapproxy/cache/riak.py", line 64, in _get_object</div><div>    key = '%(z)d_%(x)d_%(y)d' % locals()</div><div>TypeError: %d format: a number is required, not unicode</div><div><br></div></div>