On this page
  1. threading.setprofile
  2. Import
  3. Signature & Overview
  4. Usage
  5. Gotchas
  6. REPL Inspect

threading.setprofile

Prev: threading.Semaphore | Up: threading | Next: threading.setprofile_all_threads
Rel: threading.active_count, threading.Barrier, threading.BoundedSemaphore, threading.BrokenBarrierError
Ref: docs.python.org — threading.setprofile
Tags: #public #python3 #stdlib #threading


Import

import threading
from threading import setprofile

Signature & Overview

threading.setprofile(func)

Set a profile function for all threads started from the threading module.

Usage

import threading

# Registers a profiler function for all *future* Thread objects started via threading
threading.setprofile(None)

Gotchas

REPL Inspect

from threading import setprofile
help(setprofile)

Linked from

Related notes