Close #12028: Make threading._get_ident() public, rename it to
threading.get_ident() and document it. This function was used by
_thread.get_ident().
diff --git a/Lib/test/lock_tests.py b/Lib/test/lock_tests.py
index 126f97c..7bcc436 100644
--- a/Lib/test/lock_tests.py
+++ b/Lib/test/lock_tests.py
@@ -4,7 +4,7 @@
import sys
import time
-from _thread import start_new_thread, get_ident, TIMEOUT_MAX
+from _thread import start_new_thread, TIMEOUT_MAX
import threading
import unittest
@@ -31,7 +31,7 @@
self.finished = []
self._can_exit = not wait_before_exit
def task():
- tid = get_ident()
+ tid = threading.get_ident()
self.started.append(tid)
try:
f()