mirror of
https://github.com/python/cpython.git
synced 2025-10-09 16:34:44 +00:00
gh-113308: Remove some internal parts of uuid
module (#115934)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
This commit is contained in:
parent
66fb613d90
commit
61f576a5ef
3 changed files with 14 additions and 22 deletions
16
Lib/uuid.py
16
Lib/uuid.py
|
@ -567,32 +567,16 @@ def _netstat_getnode():
|
|||
# This works on AIX and might work on Tru64 UNIX.
|
||||
return _find_mac_under_heading('netstat', '-ian', b'Address')
|
||||
|
||||
def _ipconfig_getnode():
|
||||
"""[DEPRECATED] Get the hardware address on Windows."""
|
||||
# bpo-40501: UuidCreateSequential() is now the only supported approach
|
||||
return _windll_getnode()
|
||||
|
||||
def _netbios_getnode():
|
||||
"""[DEPRECATED] Get the hardware address on Windows."""
|
||||
# bpo-40501: UuidCreateSequential() is now the only supported approach
|
||||
return _windll_getnode()
|
||||
|
||||
|
||||
# Import optional C extension at toplevel, to help disabling it when testing
|
||||
try:
|
||||
import _uuid
|
||||
_generate_time_safe = getattr(_uuid, "generate_time_safe", None)
|
||||
_UuidCreate = getattr(_uuid, "UuidCreate", None)
|
||||
_has_uuid_generate_time_safe = _uuid.has_uuid_generate_time_safe
|
||||
except ImportError:
|
||||
_uuid = None
|
||||
_generate_time_safe = None
|
||||
_UuidCreate = None
|
||||
_has_uuid_generate_time_safe = None
|
||||
|
||||
|
||||
def _load_system_functions():
|
||||
"""[DEPRECATED] Platform-specific functions loaded at import time"""
|
||||
|
||||
|
||||
def _unix_getnode():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue