You have seen that threads help programs that wait. You have also been warned that they do not help programs that calculate, in standard Python. The reason is the global interpreter lock, the GIL, one of the most discussed parts of CPython. This lesson explains what it is, what it protects and what it costs, how the interpreter shares it between threads, and the change that is under way, free-threaded Python, which removes it. It ends with the rules of thumb for choosing and using threads.
More lessons in Complete Python Programming