It has become conventional wisdom to always explicitly close file-like objects, via context managers. The google style guide is representative:
It has become conventional wisdom to always explicitly close file-like objects, via context managers. The google style guide is representative: