vprof/stats_server.py
def do_GET(self):
        """Handles HTTP GET requests."""
        handler = self.uri_map.get(self.path) or self._handle_other
        content, content_type = handler()
        compressed_content = gzip.compress(content)
        self._send_response(
            200, headers=(('Content-type', '%s; charset=utf-8' % content_type),
                          ('Content-Encoding', 'gzip'),
                          ('Content-Length', len(compressed_content))))
        self.wfile.write(compressed_content)
def do_GET(self):
        handler = self.uri_map.get(self.path) or self._handle_other
        content, content_type = handler()
        compressed_content = gzip.compress(content)
        self._send_response(
            200, headers=(('Content-type', '%s; charset=utf-8' % content_type),
                          ('Content-Encoding', 'gzip'),
                          ('Content-Length', len(compressed_content))))
        self.wfile.write(compressed_content)
def do_GET ( self ) : handler = self . uri_map . get ( self . path ) or self . _handle_other content , content_type = handler ( ) compressed_content = gzip . compress ( content ) self . _send_response ( 200 , headers = ( ( 'Content-type' , '%s; charset=utf-8' % content_type ) , ( 'Content-Encoding' , 'gzip' ) , ( 'Content-Length' , len ( compressed_content ) ) ) ) self . wfile . write ( compressed_content )
Handles HTTP GET requests.
Handles HTTP GET requests .