2 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -380,6 +380,13 @@ since it is impossible to detect the termination of alien threads.
380
380
This method will raise a :exc: `RuntimeError ` if called more than once
381
381
on the same thread object.
382
382
383
+ If supported, set the operating system thread name to
384
+ :attr: `threading.Thread.name `. The name can be truncated depending on the
385
+ operating system thread name limits.
386
+
387
+ .. versionchanged :: 3.14
388
+ Set the operating system thread name.
389
+
383
390
.. method :: run()
384
391
385
392
Method representing the thread's activity.
@@ -443,9 +450,6 @@ since it is impossible to detect the termination of alien threads.
443
450
running thread is renamed. (Setting the *name * attribute of a
444
451
different thread only updates the Python Thread object.)
445
452
446
- .. versionchanged :: 3.14
447
- Set the operating system thread name.
448
-
449
453
.. method :: getName()
450
454
setName()
451
455
Original file line number Diff line number Diff line change @@ -645,6 +645,13 @@ sys.monitoring
645
645
* Two new events are added: :monitoring-event: `BRANCH_LEFT ` and
646
646
:monitoring-event: `BRANCH_RIGHT `. The ``BRANCH `` event is deprecated.
647
647
648
+ threading
649
+ ---------
650
+
651
+ * :meth: `threading.Thread.start ` now sets the operating system thread name
652
+ to :attr: `threading.Thread.name `.
653
+ (Contributed by Victor Stinner in :gh: `59705 `.)
654
+
648
655
tkinter
649
656
-------
650
657
0 commit comments