KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I'm currently trying to figure out how threads work in python. I have the following code: def func1(arg1, arg2): print current_thread() .... class class1: def __init__(): .... def func_call(): print current_thread() t1 = threading.Thread(func1(arg1, arg2)) t1.start() t1.join() What I noticed is that both prints output the same thing. Why is the thread not changing?
Tags (comma-separated)
Save Edits
Cancel