Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/dabeaz/python-cookbook
/ UDPTimeServer
Class
UDPTimeServer
src/11/event_driven_io_explained/udpserver.py:17–20 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
15
return
True
16
17
class
UDPTimeServer(UDPServer):
18
def
handle_receive(self):
19
msg, addr = self.sock.recvfrom(1)
20
self.sock.sendto(time.ctime().encode(
'ascii'
), addr)
21
22
class
UDPEchoServer(UDPServer):
23
def
handle_receive(self):
Callers
1
udpserver.py
File · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected