Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't leak an open file handle; fix Pyling R1732 (#584)
**The problem** The code had a case of a manual file handler pitfall, where a resource stream is opened manually and never closed. This pitfall was detected using Pyling, which triggered a message of code R1732 with the content "Consider using 'with' for resource-allocating operations" **The solution** Used a 'with' block to automatically close the open stream on the file just after it is no longer needed
- Loading branch information