Show pid when starting simple server.
This commit is contained in:
parent
cecb1efc4b
commit
a7bedb139d
1 changed files with 1 additions and 1 deletions
|
@ -323,7 +323,7 @@ class SimpleServer:
|
||||||
|
|
||||||
def start(self):
|
def start(self):
|
||||||
server = http.server.ThreadingHTTPServer(('0.0.0.0', self.port), self.make_request_handler)
|
server = http.server.ThreadingHTTPServer(('0.0.0.0', self.port), self.make_request_handler)
|
||||||
print(f'Server starting on {self.port}')
|
print(f'Server starting on {self.port}, pid={os.getpid()}.')
|
||||||
try:
|
try:
|
||||||
server.serve_forever()
|
server.serve_forever()
|
||||||
except KeyboardInterrupt:
|
except KeyboardInterrupt:
|
||||||
|
|
Loading…
Reference in a new issue