This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pitrou
Recipients Windson Yang, davin, docs@python, pitrou, zach.ware
Date 2018-07-07.15:47:43
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1530978464.01.0.56676864532.issue34051@psf.upfronthosting.co.za>
In-reply-to
Content
To be frank, I don't think that matters much.  The user should understand what a lock is already, if they want to make use of multiprocessing fruitfully.  The example showcases how to create a lock and how to pass it to child processes (by giving it as a function parameter).  Printing to standard output is not the important thing here.

However if you want to improve this example, you could replace the acquire/release pair with a "with" statement.
History
Date User Action Args
2018-07-07 15:47:44pitrousetrecipients: + pitrou, docs@python, zach.ware, davin, Windson Yang
2018-07-07 15:47:44pitrousetmessageid: <1530978464.01.0.56676864532.issue34051@psf.upfronthosting.co.za>
2018-07-07 15:47:44pitroulinkissue34051 messages
2018-07-07 15:47:43pitroucreate