Need a quick HTTP server? Here is one.
import http
import http.server
class MyHandlerClass(http.server.BaseHTTPRequestHandler):
def do_GET(self):
print("Inside GET callback")
self.send_response(http.HTTPStatus.OK)
self.send_header('Content-Type', 'text/plain')
self.end_headers()
self.wfile.write(b'Hello, world!')
s = http.server.HTTPServer(
('localhost', 49152), MyHandlerClass
)
s.serve_forever()