Python thread

From wikinotes
Revision as of 17:24, 15 February 2019 by Will (talk | contribs) (Created page with " The oldest threading interface for python. <source lang="python"> import thread thread.start_new_thread(func, ('argA',), {'kwargA': 1}) lock = thread.allocate_lock() lock...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The oldest threading interface for python.

import thread

thread.start_new_thread(func, ('argA',), {'kwargA': 1})

lock = thread.allocate_lock()
lock.acquire()
lock.release()