import SimpleHTTPServer

SimpleHTTPServerをimportする。

[vagrant@localhost python]$ python
Python 2.7.14 (default, Mar 12 2018, 22:03:33)
[GCC 5.4.0 20160609] on linux2
Type “help”, “copyright”, “credits” or “license” for more information.
>>> import SimpleHTTPServer
>>> SimpleHTTPServer.test()
Serving HTTP on 0.0.0.0 port 8000 …
192.168.33.1 – – [21/Jul/2018 22:28:14] “GET / HTTP/1.1” 200 –
192.168.33.1 – – [21/Jul/2018 22:28:14] code 404, message File not found
192.168.33.1 – – [21/Jul/2018 22:28:14] “GET /favicon.ico HTTP/1.1” 404 –
192.168.33.1 – – [21/Jul/2018 22:28:18] “GET /app.py HTTP/1.1” 200 –

ん?どういうことだ?