def render_GET(self, request):
        if len(request.postpath) == 0:
            return respond(request, {'keys': self.collector.keys(), 'stats': self.collector.stats.stats()})
        else:
            def convert(v):
                if isinstance(v, TimingStat):
                    return v.to_dict()
                return v

            name = '/'.join(request.postpath)

            output = {}
            try:
                for n in name.split(','):
                    output[n] = [(date, convert(value)) for date, value in self.collector.get(n)]
            except __HOLE__:
                return respond(request, dict(code=404, error="Not Found"), code=404);

            if ',' in name:
                return respond(request, output)
            else:
                return respond(request, output[name])
dataset/ETHPy150Open wadey/python-ostrich/ostrich/twisted/__init__.py/TimeSeriesDataResource.render_GET