add: basics

This commit is contained in:
Дмитрий Абдрахманов 2024-09-09 10:01:44 +03:00
commit 9185bec3fe
8 changed files with 14 additions and 0 deletions

0
README.md Normal file
View File

0
main.sh Normal file
View File

0
src/ requirements.txt Normal file
View File

Binary file not shown.

Binary file not shown.

3
src/main.py Normal file
View File

@ -0,0 +1,3 @@
from server import run
run()

11
src/server.py Normal file
View File

@ -0,0 +1,11 @@
from http.server import BaseHTTPRequestHandler, HTTPServer
import json
def run(server_class=HTTPServer, handler_class=BaseHTTPRequestHandler):
server_address = ("", 8000)
httpd = server_class(server_address, WeatherHandler)
httpd.serve_forever()
class WeatherHandler(BaseHTTPRequestHandler):
def do_GET(self):
return self.render(404)

0
src/weather.py Normal file
View File