Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

You can do anything you want with a context manager, it's just Python. IIRC, they were first added to the language to get rid of boilerplate while acquiring/releasing locks to make multi-threading easier.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: