News for hackers. Stuff that matters.
Re:Practical threaded programming with Python by japaget on Thursday August 15, 2013 @01:45PM (#6219460)
The article is from 2008, so it applies to Python 2. I don't know enough about threading to say whether the same code will work in Python 3.
Re:Practical threaded programming with Python by briancurtin on Thursday August 15, 2013 @02:47PM (#6219807)
It will. If you just tweak some things in the examples like urllib2 imports and print-as-a-statement usage, the threading API is the same so it's still generally relevant.
Re:Practical threaded programming with Python by andrewcooke on Thursday August 15, 2013 @05:05PM (#6220607)
it probably predates the multiprocessing package (introduced in 2.6, october 2008, although available 3rd party before that) and certainly doesn't mention it.

multiprocessing does use multiple cores, but is a heavyweight solution (separate, communicating processes, wrapped in a thread-like api). if you need multiple threads for cpu-related performance, it can be very useful.

python 2.6+, including 3.

http://toastdriven.com/blog/2008/nov/11/brief-introduction-m...

http://docs.python.org/2/library/multiprocessing.html