We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4752f84 commit 44c5ed9Copy full SHA for 44c5ed9
Lib/socket.py
@@ -67,6 +67,11 @@
67
"has_dualstack_ipv6", "AddressFamily", "SocketKind"]
68
__all__.extend(os._get_exports_list(_socket))
69
70
+def __getattr__(name):
71
+ if name == "SocketType":
72
+ return _socket.socket
73
+ raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
74
+
75
76
# Set up the socket.AF_* socket.SOCK_* constants as members of IntEnums for
77
# nicer string representations.
0 commit comments