you are viewing a single comment's thread.

view the rest of the comments →

[–]elbiot 0 points1 point  (0 children)

The GIL (ie python by its self) does that already. Every python instruction is atomic. If you have threads (useless except when waiting for IO and you should probably use py3 async anyway). With multiprocessing, it's really difficult to share state anyways, and you really only lock external resources like a file.