dabeaz/python-cookbook — pull request #4 by isaacl (2014-01-04 20:44:07+00:00)
Title: Various fixes

- Fixed racy anti-patterns
if os.path.exists(path):
# open(path)

if args in self.__cache: # __cache is weakref dict
# self.__cache[args]

- Modified deadlock context to work with RLocks.
- Added sleeps to fast printing example.