mirror of https://github.com/python/cpython
gh-91217: deprecate telnetlib (GH-91958)
This commit is contained in:
parent
4153f2cbcb
commit
1af871eeee
|
@ -1069,6 +1069,7 @@ Deprecated
|
|||
* :mod:`sndhdr`
|
||||
* :mod:`spwd`
|
||||
* :mod:`sunau`
|
||||
* :mod:`telnetlib`
|
||||
|
||||
(Contributed by Brett Cannon in :issue:`47061`.)
|
||||
|
||||
|
|
|
@ -37,6 +37,9 @@ import sys
|
|||
import socket
|
||||
import selectors
|
||||
from time import monotonic as _time
|
||||
import warnings
|
||||
|
||||
warnings._deprecated(__name__, remove=(3, 13))
|
||||
|
||||
__all__ = ["Telnet"]
|
||||
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
import socket
|
||||
import selectors
|
||||
import telnetlib
|
||||
import threading
|
||||
import contextlib
|
||||
|
||||
from test import support
|
||||
from test.support import socket_helper
|
||||
from test.support import socket_helper, warnings_helper
|
||||
import unittest
|
||||
|
||||
support.requires_working_socket(module=True)
|
||||
|
||||
telnetlib = warnings_helper.import_deprecated('telnetlib')
|
||||
|
||||
HOST = socket_helper.HOST
|
||||
|
||||
def server(evt, serv):
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Deprecate the telnetlib module.
|
Loading…
Reference in New Issue